From 68e2b57e2cffc4c4cad762b94732d7559db1d00f Mon Sep 17 00:00:00 2001 From: "Michael H.G. Schmidt" Date: Mon, 2 Jan 2023 11:12:06 +0100 Subject: [PATCH] improvements --- 07_PrepareStick.cmd | 16 ++++++++++++---- scripts/copy-executables.cmd | 1 + scripts/startmenu/MediaCreationTool20H2.lnk | Bin 0 -> 1077 bytes 3 files changed, 13 insertions(+), 4 deletions(-) create mode 100644 scripts/startmenu/MediaCreationTool20H2.lnk diff --git a/07_PrepareStick.cmd b/07_PrepareStick.cmd index be3b7d0..e600025 100644 --- a/07_PrepareStick.cmd +++ b/07_PrepareStick.cmd @@ -1,7 +1,9 @@ @echo off +set COPY_IMAGE=null IF %1.==. GOTO USAGE IF %2.==. GOTO USAGE +IF "%~3" NEQ "" set COPY_IMAGE=%3 echo. echo ==================== @@ -37,8 +39,13 @@ echo using image %ISOFILE% ... echo mounting disk image (iso) with powershell ... powershell Mount-DiskImage -ImagePath %ISOFILE% -echo copying files from image to targetpath %USBDRIVE% ... -robocopy \\.\CDROM0 %USBDRIVE% /MIR /256 /NFL /NDL /R:10 /XF *.wim +if /I %COPY_IMAGE% == /W ( + echo copying files from image to targetpath %USBDRIVE% ... + robocopy \\.\CDROM0 %USBDRIVE% /MIR /256 /NFL /NDL /R:10 +) else ( + echo copying files from image to targetpath %USBDRIVE% ... + robocopy \\.\CDROM0 %USBDRIVE% /MIR /256 /NFL /NDL /R:10 /XF *.wim +) echo unmounting disk image (iso) ... powershell Dismount-Diskimage -ImagePath %ISOFILE% @@ -52,7 +59,8 @@ rem ===== GOTO END :USAGE -echo "usage: %0 " - +echo "usage: %0 [/w]" +echo /w = copy windows images to target +echo. :END diff --git a/scripts/copy-executables.cmd b/scripts/copy-executables.cmd index ec1f5b7..3e2e9bb 100644 --- a/scripts/copy-executables.cmd +++ b/scripts/copy-executables.cmd @@ -14,6 +14,7 @@ for %%E in ( puttygen.exe rufus.exe Windows-ISO-Downloader.exe + MediaCreationTool20H2.exe ) do ( diff --git a/scripts/startmenu/MediaCreationTool20H2.lnk b/scripts/startmenu/MediaCreationTool20H2.lnk new file mode 100644 index 0000000000000000000000000000000000000000..78f12c52d37d81fd274378ed3792c0366718a61d GIT binary patch literal 1077 zcmbVLO=uHQ5dP9uNmMk^D6wd|tO%*Xb`!i9TG=*D8nK}%4Y7qFjZKOx`6=0mIf!_) z5-(LRic(6opv|FB@uUdC~TSv8#s(Qde8ze|eeh}=PWBt-tv_1+^5)N7>9+{9RC8LiYe z%{{P;tC{#kH504MfImN8&lD6}&*HLg@o8t$XX+1&*KU<8cix1oKljfo|65K8;DTD%$?15t8x!;;=(3D$ zxipoZ_Hv*?s68W|Um