mirror of
https://github.com/bin456789/reinstall.git
synced 2025-01-19 04:49:13 +08:00
windows: workaround install.esd
This commit is contained in:
parent
297f834936
commit
d166302650
@ -93,16 +93,22 @@
|
|||||||
<settings pass="specialize">
|
<settings pass="specialize">
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="%arch%" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
<component name="Microsoft-Windows-Deployment" processorArchitecture="%arch%" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
|
<!-- 启用 administrator 账户 -->
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Path>net user Administrator /active:yes</Path>
|
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
|
<Path>net user Administrator /active:yes</Path>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
|
<!-- workaround esd 里面没有这个文件,先touch -->
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>2</Order>
|
<Order>2</Order>
|
||||||
|
<Path>cmd /c type nul >>C:\resize.bat</Path>
|
||||||
|
</RunSynchronousCommand>
|
||||||
|
<RunSynchronousCommand wcm:action="add">
|
||||||
|
<Order>3</Order>
|
||||||
<Path>C:\resize.bat</Path>
|
<Path>C:\resize.bat</Path>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>3</Order>
|
<Order>4</Order>
|
||||||
<Path>cmd /c "del C:\resize.bat"</Path>
|
<Path>cmd /c "del C:\resize.bat"</Path>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
|
10
trans.sh
10
trans.sh
@ -516,10 +516,12 @@ EOF
|
|||||||
# windows 7 没有 invoke-webrequest
|
# windows 7 没有 invoke-webrequest
|
||||||
# installer分区盘符不一定是D盘
|
# installer分区盘符不一定是D盘
|
||||||
# 所以复制 resize.bat 到 install.wim
|
# 所以复制 resize.bat 到 install.wim
|
||||||
image_name=$(wiminfo $install_wim | grep -ix "Name:[[:blank:]]*$image_name" | cut -d: -f2 | xargs)
|
# TODO: 由于esd文件无法修改,要将resize.bat放到boot.wim
|
||||||
wimmountrw $install_wim "$image_name" /wim/
|
if [[ "$install_wim" = "*.wim" ]]; then
|
||||||
download $confhome/resize.bat /wim/resize.bat
|
wimmountrw $install_wim "$image_name" /wim/
|
||||||
wimunmount --commit /wim/
|
download $confhome/resize.bat /wim/resize.bat
|
||||||
|
wimunmount --commit /wim/
|
||||||
|
fi
|
||||||
|
|
||||||
# 添加引导
|
# 添加引导
|
||||||
if [ -d /sys/firmware/efi/ ]; then
|
if [ -d /sys/firmware/efi/ ]; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user