-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
In some cases, it is needed to temporary change the workdir. After which some relative paths became inacessible. So, the main fix is to use abs paths for the mentioned cases.
- Loading branch information
Showing
6 changed files
with
44 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,35 @@ | ||
@echo off | ||
|
||
rem -------------------------------------------------------------------------- | ||
rem Extracts the Windows SDK Installers from the [ISO] to the [INSTALLERS] dir. | ||
rem Extracts the Windows SDK Installers from the [iso] to the [installers] dir. | ||
rem | ||
rem Using: | ||
rem | ||
rem extract-installers [ISO] [INSTALLERS] | ||
rem extract-installers [iso] [installers] | ||
rem -------------------------------------------------------------------------- | ||
|
||
setlocal | ||
|
||
set iso=%~1 | ||
set installers=%~2 | ||
set files_to_extract=Installers\*.msi Installers\*.cab | ||
|
||
call which 7z >NUL 2>&1 && ( | ||
echo|set/p=- Extracting SDK Installers ... | ||
set files=Installers\*.msi Installers\*.cab | ||
7z e -y -o"%installers%" "%iso%" -r %files% >NUL || ( | ||
7z e -y -o"%installers%" "%iso%" -r %files_to_extract% >NUL || ( | ||
echo FAIL | ||
exit /b 1 | ||
) | ||
call check-installers "%installers%" || ( | ||
echo FAIL | ||
exit /b 1 | ||
) | ||
echo OK | ||
goto :END | ||
exit /b 0 | ||
) | ||
|
||
call extract-installers-from-drive "%iso%" "%installers%" || exit /b 1 | ||
|
||
:END | ||
del /q /s "%iso%" >NUL 2>&1 || echo [WARN][%~n0] Unable to delete "%iso%"! | ||
exit /b 0 | ||
call extract-installers-from-drive "%iso%" "%installers%" ^ | ||
&& exit /b 0 ^ | ||
|| exit /b 1 | ||
|
||
endlocal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -76,5 +76,5 @@ echo. | |
endlocal | ||
|
||
:SET_PATH | ||
set "PATH=%~1;%PATH%" | ||
set "PATH=%~f1;%PATH%" | ||
exit /b 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters