|
23.改进ISO内核加载方式,如果在硬盘或U盘中启动PE,将以可写方式挂载,重新挂载时也将是可写挂载,方便了浏览器加载、杀毒软件即时升级及DIY:
步骤是:首先辨别winpe.ini所在磁盘是否可写,如不可写,以pecmd moun方式加载,如可写,以imagex /mountrw 可写挂载。。。。。。
方法可能是笨了点,不知道大家有什么好的建议??
这是我暂时改写的ISO内核的 winpe.ini
_sub mountwimfile
name wimname=%swim%
find $%inmoun%=n,moun %swim%,%mountpath%\%wimname%\,1!team PATH %mountpath%\%wimname%|exec =!%inmoun% %swim% 1 %mountpath%\%wimname%
load %mountpath%\%wimname%\main.ini
find $%ynmoun%=y,!Exec =!cmd.exe /c "echo moun %swim%,%mountpath%\%wimname%\,">>X:\moun.ini
find $%inmoun%=n,!Exec =!cmd.exe /c "echo exec =!%inmoun% %swim% 1 %mountpath%\%wimname%">>X:\moun.ini
Exec =!cmd.exe /c "echo load %mountpath%\%wimname%\main.ini">>X:\moun.ini
Exec =!cmd.exe /c "echo load %mountpath%\%wimname%\inmain.ini">>X:\moun.ini
Exec =!cmd.exe /c "echo moun %mountpath%\%wimname%,">>X:\unmoun.ini
_end
ifex x:\wxpe\LOADOP.INI,!exec !cmd.exe /c "copy LOADOP.INI x:\wxpe\LOADOP.INI /y"
NUMK 0 `对于台式机键盘,改成 NUMK 1
`先加载内置的.wim,主要是里面有步步为营的imgex.exe,另一个原因是避免重新挂载时的重复执行。启动后,自动生成的重新挂载列表中也不包括这个.wim信息了。
TEAM TEXT 正在加载二级内核与外置程序……#0xEE,$20|WAIT 500
moun %curdrv%\minipe\WCINOP.wim,Y:\WCINOP,1
load Y:\WCINOP\main.ini
`判断外置文件所在磁盘是否可写,,然后执行mountwimfile子程序
PATH %curdrv%\mdtemp
ifex %curdrv%\mdtemp,team file %curdrv%\mdtemp|envi ynmoun=y|envi inmoun=X:\Program Files\步步为营IMAGEX备份还原工具\imagex_6001\x86\imagex.exe /mountrw!envi inmoun=n
team envi soft=%curdrv%\minipe|envi bsc=%soft%\programs|envi sys=%soft%\system|envi pf=pagefile.sys
FIND MEM<257,PAGE D:\%PF% 256 372
envi mountpath=Y:
forx %sys%\*.wim,swim,0,call mountwimfile
envi mountpath=Y:
Exec !cmd.exe /c "echo set ynmoun=%ynmoun%>X:\inmoun.cmd
Exec !cmd.exe /c "echo envi mountpath=%mountpath%>X:\inpath.ini
forx %bsc%\*.wim,swim,0,call mountwimfile
Exec !cmd.exe /c "echo file %USERPROFILE%\桌面\加载外部配置.lnk>>X:\moun.ini
ifex %curdrv%\安装WinPE.EXE,link %startmenu%\winpe安装程序,%curdrv%\安装WinPE.EXE `开始菜单建立自动播放快捷方式
ifex %bsc%\internet explorer.wim,envi $path=%path%;%programfiles%\internet explorer
[ 本帖最后由 网虫2008 于 2010-1-13 01:12 编辑 ] |
|