From 6caf031e42d6049df97befd13c28308cd7f6d0b6 Mon Sep 17 00:00:00 2001 From: dragonflylee Date: Mon, 27 May 2019 22:55:37 +0800 Subject: [PATCH] fix --- WimExport.cmd | 26 +++++--------------------- WimHelper.cmd | 4 ++++ 2 files changed, 9 insertions(+), 21 deletions(-) diff --git a/WimExport.cmd b/WimExport.cmd index f2d62f6..13e4a67 100644 --- a/WimExport.cmd +++ b/WimExport.cmd @@ -11,7 +11,7 @@ set "ESDPath=%~1" if "%ESDPath%" equ "" call :SelectFolder if "%ESDPath%" equ "" goto :Exit rem call :ExportISO "E G", "%~dp0install.wim" -for %%i in (X64) do call :ExportRS5 "%ESDPath%", "%~dp0DVD_%%i", "%%i" +for %%i in (X64) do call :Export19H1 "%ESDPath%", "%~dp0DVD_%%i", "%%i" goto :Exit :SelectFolder @@ -42,31 +42,15 @@ if not exist "%WimPath%" goto :eof call :MakeISO "%WimPath%", "%~2" goto :eof -rem 导出RS3镜像 [ %~1 : 源路径, %~2 : 目标路径, %~3 处理器架构 ] -:ExportRS3 +rem 导出19H1镜像 [ %~1 : 源路径, %~2 : 目标路径, %~3 处理器架构 ] +:Export19H1 if not exist "%~1" echo [%~1] 不存在 && goto :eof -set "WimPath=%~dp0install_RS3_%~3_%date:~0,4%%date:~5,2%%date:~8,2%.wim" +set "WimPath=%~dp0install_19H1_%~3_%date:~0,4%%date:~5,2%%date:~8,2%.wim" call :RemoveFile "%WimPath%" call :RemoveFolder "%~2" rem 导出安装镜像 for %%i in (china consumer business) do ( - for %%j in ("%~1\*.rs3_release_*%%i*_%~3fre_*.esd") do ( - if not exist "%~2" call :ExportDVD "%%j", "%~2" - call :ExportImage "%%j", "%WimPath%" - ) -) -call :MakeISO "%WimPath%", "%~2" -goto :eof - -rem 导出RS5镜像 [ %~1 : 源路径, %~2 : 目标路径, %~3 处理器架构 ] -:ExportRS5 -if not exist "%~1" echo [%~1] 不存在 && goto :eof -set "WimPath=%~dp0install_RS5_%~3_%date:~0,4%%date:~5,2%%date:~8,2%.wim" -call :RemoveFile "%WimPath%" -call :RemoveFolder "%~2" -rem 导出安装镜像 -for %%i in (china consumer business) do ( - for %%j in ("%~1\*.rs5_release_*%%i*_%~3fre_*.esd") do ( + for %%j in ("%~1\*.19h1_release_*%%i*_%~3fre_*.esd") do ( if not exist "%~2" call :ExportDVD "%%j", "%~2" call :ExportImage "%%j", "%WimPath%" ) diff --git a/WimHelper.cmd b/WimHelper.cmd index 78c936e..b672254 100644 --- a/WimHelper.cmd +++ b/WimHelper.cmd @@ -112,10 +112,13 @@ rem :lopatkin rem 修复默认用户头像 xcopy /E /I /H /R /Y /J "%SRC%\ProgramData\Microsoft\User Account Pictures\*.*" "%~1\ProgramData\Microsoft\User Account Pictures" >nul + call :MountImageRegistry "%~1" rem 修复默认主题 call :RemoveFolder "%~1\Windows\Web\Wallpaper\Theme1" call :RemoveFile "%~1\Windows\Resources\Themes\Theme1.theme" +move "%~1\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Калькулятор.lnk" "%~1\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Calculator.lnk" +notepad "%~1\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\desktop.ini" reg add "HKLM\TK_SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\LastTheme" /v "ThemeFile" /t REG_EXPAND_SZ /d "%%SystemRoot%%\Resources\Themes\Aero.theme" /f >nul rem 修复设备管理器英文 for /f "tokens=2 delims=@," %%j in ('reg query "HKLM\TK_SYSTEM\ControlSet001\Control\Class" /v "ClassDesc" /s ^| findstr /i inf') do ( @@ -124,6 +127,7 @@ for /f "tokens=2 delims=@," %%j in ('reg query "HKLM\TK_SYSTEM\ControlSet001\Con ) ) call :UnMountImageRegistry +rem call :AddAppx "%~1", "Store", "VCLibs.14 Runtime.1.7 Framework.1.7" call :RemoveFolder "%~1\Program Files (x86)\Trey" call :RemoveFolder "%~1\Program Files\Trey" call :RemoveFile "%~1\Users\Default\Desktop\Green Christmas Tree.lnk"