#!/bin/sh . /usr/local/auth/sbrf/ukm_sbrf_functions.sh sbrf_mode_on ./config sbrf_mode_off
#!/bin/sh SBRFDIR=/usr/local/auth/sbrf sudo $SBRFDIR/ukm_runsbrf_in.sh $@ exit 0
#!/bin/sh . /usr/local/auth/sbrf/ukm_sbrf_functions.sh umask 0000 chvt 2 chvt 1 sbrf_mode_on export LANG=ru_RU.KOI8-R ./sb_pilot $@ sbrf_mode_off
#!/bin/bash . /usr/local/auth/sbrf/ukm_sbrf_functions.sh sbrf_mode_on ./sb_pilot sbrf_mode_off
#!/bin/sh DIR_START="$(pwd)" DIR_UKM_SBRF="/usr/local/auth/sbrf" FILE_LOG="$DIR_UKM_SBRF/ukmsbrf.log" FILE_E="$DIR_UKM_SBRF/e" FILE_P="$DIR_UKM_SBRF/p" FILE_DISPLAY_LOG="display.log" catv() { local fname=$1 local srcenc=$2 if [ -f $fname ]; then echo echo "-- $fname ---------------" echo tail -n 500 $fname | iconv -f $srcenc -t utf-8 echo echo "-- $fname ---------------" echo else echo "catv() File $fname not found" fi } catv_koi8r() { local fname=$1 catv $fname koi8r } catv_cp866() { local fname=$1 catv $fname cp866 } logstate() { local label=$1 echo echo "---- $(date) $label -----------------------------" echo echo ls -la $DIR_UKM_SBRF echo catv_koi8r $FILE_E catv_koi8r $FILE_P catv_cp866 $FILE_DISPLAY_LOG echo echo "---- $(date) $label -----------------------------" echo } reset_term() { clear /sbin/setsysfont setleds -D ${1}num < /dev/console } sbrf_mode_on() { logstate 'sbrf_mode_on() begin' >> $FILE_LOG reset_term + cd $DIR_UKM_SBRF unicode_stop setfont koi8u_8x16 -u koi8u -m koi8-u_to_uni.trans loadkeys -c -s ukm-sbrf.map logstate 'sbrf_mode_on() end' >> $FILE_LOG } sbrf_mode_off() { logstate 'sbrf_mode_off() begin' >> $FILE_LOG 2>&1 reset_term - . /etc/sysconfig/keyboard loadkeys $KEYTABLE cd $DIR_START logstate 'sbrf_mode_off() end' >> $FILE_LOG 2>&1 }