|
因为是公共机器,一直被人还原恢复系统搞坏数据,整烦了,所以我用策略把还原类软件在windows下限制,把所有还原软件都卸载了。只保留硬盘工具箱。而且想让开机的字符提示不显示在屏幕上,这样只有我知道按快捷键可以出现菜单。
!BAT
::if exist preload exit
terminal console
clear
echo
echo -P:0205 $[1105]System Checking...
::do not display cursor
call Fn.70 0
set NTBOOT=%~dp0NTBOOT/NTBOOT
set AddonDir=%~dp0ADDONS
set BootDir=%~dp0
set BootDir=%BootDir:~0,-1%
set ModBoot=%~dp0MODBOOT/MODBOOT.BAT
setlocal
debug off
set QGHO.CHK=%~dp0MODBOOT/QGHO/QGHO.CHK
find --set-root --devices=h makeactive --status && %QGHO.CHK% || echo -n
find --set-root --devices=h /qgho.### && goto :QGHO_FAST
:start
%BootDir%/grub/vfont %BootDir%/preload.fnt
clear
echo
if exist QGHO.GHO && echo -P:0910 $[0105]Press $[1102]F9$[0105] To Restore System && echo -P:1210 $[0106]纮 $[1102]F9$[0106] 羴聜脙膭 $[0102] %QGHO.OS% on %QGHO.SRC%
if exist QGHO.GHO || echo -P:0910 $[0105]Press $[1102]F9$[0105] To Backup System && echo -P:1210 $[0106]纮 $[1102]F9$[0106] 艆茊脙膭 $[0102] %QGHO.OS% on %QGHO.SRC%
echo -P:2420 $[0102]GRUB4DOS 菄葓蓧蕣藡, $[0106]by chenall http://chenall.net
echo -P:00-12 $[0107]%@DATE%
echo -P:02-13 $[0101]F8 $[0107]SysMenu
echo -P:03-18 $[0103]Ctrl+F8 $[0107]ReChk
echo -P:05-18 $[0102]Ctrl+F9 $[0107]QGHO
echo -P:07-18 $[0103]Ctrl+C $[0107]SHELL
pause --test-key --wait=5
set /A key=*0x4CB00
%BootDir%/grub/vfont
clear
debug off
goto %key% || echo -n
:0x3B00 F1
:0x3C00 F2
:0x3D00 F3
:0x3E00 F4
:0x3F00 F5
:0x4000 F6
:0x4100 F7
:0x4400 F10
:0x8500 F11
:0x8600 F12
:1
:default
if exist %BootDir%/OEMSLIC.BIN && %BootDir%/GRUB/SLIC %BootDir%/OEMSLIC.BIN
if exist %BootDir%/SYS_MENU.LST && configfile %BootDir%/SYS_MENU.LST
if "%QGHO.OS%=="Unknown System" && goto :0x4200
echo Default Boot: $[0102]%QGHO.OS% on %QGHO.SRC%
chainloader %QGHO.SRC%+1
boot
goto :start
:0x4200 F8
cat --length=1 %BootDir%/GRUB/DEFSYS.LST | set a=
if not exist a && goto :0x6500
configfile %BootDir%/GRUB/DEFSYS.LST
goto :default
:0x6500 Ctrl+F8
echo -P:0205 $[1105]System Checking...
%BootDir%/GRUB/DEFSYS.BAT || Pause Unknown Error.
configfile %BootDir%/GRUB/DEFSYS.LST
exit
:check_pwd
if not exist QGHO.PWD && exit
password --md5 %QGHO.PWD% && exit
call Fn.4
checkrange 0:0xff read 0x4cb00 || exit 1
goto :check_pwd
:0x2e03 Ctrl+C
commandline
goto :start
:0x6600 Ctrl+F9
call :check_pwd || goto :start
%BootDir%/grub/vfont
%ModBoot% boot=/LEVEL3/QGHO.ZIP || endlocal @
goto :start
:0x4300 F9
if exist QGHO.GHO || goto :QGHO_START
call :check_pwd || goto :start
:QGHO_START
clear
%BootDir%/grub/vfont
%ModBoot% boot=/LEVEL3/QGHO.ZIP QGHO=AUTO %QGHO.SRC% || endlocal @
goto :start
:QGHO_FAST
clear
echo
echo -P:1520 $[1102]QGHO Fast Restore Checking....
echo $[0106] QGHO Fast Restore configfile: $[0105]%@root%/QGHO.###
cat [email=%@root%/QGHO]%@root%/QGHO[/email].###
echo
%ModBoot% boot=/LEVEL3/QGHO.ZIP [email=fast=%@root%/QGHO]fast=%@root%/QGHO[/email].### || endlocal @
goto :start
:0x5D00 Shift+F10
color blue/green yellow/red white/magenta white/magenta
command --set-path=(bd)/BOOT/GRUB/
ls %AddonDir%/# > (md)0x300+4 || configfile %BootDir%/GRUB/tools.lst
cmp (md)0x300+4 %BootDir%/GRUB/ADDONS.LST && configfile %BootDir%/GRUB/tools.lst
clear
echo
echo $[1106]Loading addons......
map --rd-base=0x800
map --rd-size=0x1000
cat %BootDir%/GRUB/MENU.DEF > (rd)+1
set number=5
cat (md)0x300+4 | call :ADDONS=
dd if=(rd)+1 of=%BootDir%/GRUB/tools.lst || Pause Write file error %BootDir%/GRUB/tools.lst
dd if=(md)0x300+4 of=%BootDir%/GRUB/ADDONS.LST || Pause Write file error %BootDir%/GRUB/ADDONS.LST
configfile (rd)+1
goto :start
:ADDONS
if "%1"=="" exit
set number= |
|