From ac730761a4ef9657c8889004c1589d9fafc5e58c Mon Sep 17 00:00:00 2001 From: "Michael H.G. Schmidt" Date: Sun, 21 Feb 2021 15:43:09 +0100 Subject: [PATCH] . --- README.md | 3 ++- software/download-software.cmd | 30 ++++++++++++++++++++++++++++++ software/softwarelist.csv | 1 + wim/remove-packages.cmd | 1 - 4 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 software/download-software.cmd create mode 100644 software/softwarelist.csv diff --git a/README.md b/README.md index 10134dd..c66814e 100644 --- a/README.md +++ b/README.md @@ -167,7 +167,7 @@ setx PATH %SYSTEMROOT%;%SYSTEMROOT%\system32;%SYSTEMROOT%\system32\wbem;%SYSTEMR ``` -# 3 Clone this repository +# 3. Clone this repository ```dos cd /D %USERPROFILE% @@ -177,3 +177,4 @@ git clone https://github.com/mhgschmidt/w10install.git cd w10install ``` + diff --git a/software/download-software.cmd b/software/download-software.cmd new file mode 100644 index 0000000..3dda8c0 --- /dev/null +++ b/software/download-software.cmd @@ -0,0 +1,30 @@ +@echo off +set LISTFILE=softwarelist.csv + +IF NOT EXIST %LISTFILE% ( + echo ERROR: %LISTFILE% not found! + exit /b +) + +rem ################################### +rem MAIN loop ( download software ) ... +rem ################################### + +FOR /F "tokens=1,2 delims=, " %%E in (%LISTFILE%) do ( + echo getting: [ %%E ] from [ %%F ] + + curl -L %%E --output %%F + + IF %%~zF == 0 ( + echo ERROR: size of %%F is 0 bytes + del /F %%F + ) ELSE ( + echo INFO: size of %%F is %%~zF bytes + ) + + if NOT EXIST %%F ( + echo ERROR: couldn't get %%F! + exit /b + ) + +) diff --git a/software/softwarelist.csv b/software/softwarelist.csv new file mode 100644 index 0000000..801cdcd --- /dev/null +++ b/software/softwarelist.csv @@ -0,0 +1 @@ +http://download.spotify.com/SpotifyFullSetup.exe spotify.exe diff --git a/wim/remove-packages.cmd b/wim/remove-packages.cmd index 2d155c4..7bf624e 100644 --- a/wim/remove-packages.cmd +++ b/wim/remove-packages.cmd @@ -204,4 +204,3 @@ move /Y Packages.txt Packages-AFTER.txt rem showing packages ... dir Packages*.txt -