TA的每日心情 | 开心 2024-8-30 14:29 |
---|
|
@echo off
rem boot.wim处理
rem 查看boot.wim中有几个index,驱动和补丁打在每个index下
dism /Get-WimInfo /WimFile:boot.wim
rem index1
rem 将boot.wim的index 1 挂载载mtdir下
dism /Mount-Wim /WimFile:boot.wim /index:1 /MountDir:mtdir
rem 打上驱动
dism /Image:mtdir /Add-Driver /Driver:drivers /Recurse
rem 打上补丁
dism /Image:mtdir /Add-Package /PackagePath:hotfix
rem //卸载mtdir,卸载中注意需要关闭资源管理器,关闭defender
dism /UnMount-Wim /MountDir:mtdir /Commit
rem index2
rem 将boot.wim的index 2 挂载载mtdir下
dism /Mount-Wim /WimFile:boot.wim /index:1 /MountDir:mtdir
rem 打上驱动
dism /Image:mtdir /Add-Driver /Driver:drivers /Recurse
rem 打上补丁
dism /Image:mtdir /Add-Package /PackagePath:hotfix
rem 卸载mtdir
dism /UnMount-Wim /MountDir:mtdir /Commit
rem install.wim 处理
dism /Get-WimInfo /WimFile:\install.wim //查看.wim中有几个index,驱动和补丁打在每个index下
rem index1
dism /Mount-Wim /WimFile:install.wim /index:1 /MountDir:mtdir
dism /Image:mtdir /Add-Driver /Driver:drivers /Recurse
dism /Image:mtdir /Add-Package /PackagePath:hotfix
dism /UnMount-Wim /MountDir:mtdir /Commit
rem index2
dism /Mount-Wim /WimFile:install.wim /index:2 /MountDir:mtdir
dism /Image:mtdir /Add-Driver /Driver:drivers /Recurse
dism /Image:mtdir /Add-Package /PackagePath:hotfix
dism /UnMount-Wim /MountDir:mtdir /Commit
rem index3
dism /Mount-Wim /WimFile:install.wim /index:3 /MountDir:mtdir
dism /Image:mtdir /Add-Driver /Driver:drivers /Recurse
dism /Image:mtdir /Add-Package /PackagePath:hotfix
dism /UnMount-Wim /MountDir:mtdir /Commit
rem index4
dism /Mount-Wim /WimFile:install.wim /index:4 /MountDir:mtdir
dism /Image:mtdir /Add-Driver /Driver:drivers /Recurse
dism /Image:mtdir /Add-Package /PackagePath:hotfix
dism /UnMount-Wim /MountDir:mtdir /Commit
|
|