Change subroutine args order in mkunlist.cmd

This commit is contained in:
bitraid 2018-07-28 09:36:25 +03:00
parent 5b31576b57
commit 51aee6fe8e
No known key found for this signature in database
GPG Key ID: 140D99CA504654D3
1 changed files with 5 additions and 5 deletions

View File

@ -17,20 +17,20 @@ if not exist "%DIST%" exit 2
if exist "%ULIST%" del "%ULIST%" || exit 3
if exist "%DLIST%" del "%DLIST%" || exit 3
for /r "%DIST%" %%i in (*) do call:AddToNSH "%%i" Delete "%ULIST%"
for /r "%DIST%" %%i in (*) do call:AddToNSH Delete "%%i" "%ULIST%"
rem '*' doesn't catch hidden files and there are a couple files starting with
rem a '.', which will appear as hidden if mapped from a linux file system.
for /f "tokens=*" %%i in ('dir "%DIST%" /a:h-d /b /s') do call:AddToNSH "%%i" Delete "%ULIST%"
for /f "tokens=*" %%i in ('dir "%DIST%" /a:h-d /b /s') do call:AddToNSH Delete "%%i" "%ULIST%"
for /r "%DIST%" %%i in (.) do call:AddToNSH "%%i" RMDir "%DLIST%"
for /r "%DIST%" %%i in (.) do call:AddToNSH RMDir "%%i" "%DLIST%"
sort /r "%DLIST%" >> "%ULIST%"
del "%DLIST%"
goto:eof
:AddToNSH
set "FN=%~1"
set "FN=%~2"
set "FN=!FN:%DIST%=!"
set "FN=!FN:$=$$!"
(echo:%2 "$INSTDIR!FN!") >> %3
(echo:%1 "$INSTDIR!FN!") >> %3