[Project64] Fix version script to work with spaces in name

This commit is contained in:
zilmar 2016-07-04 19:06:00 +10:00
parent 836fe7e8b4
commit cb6fd2a15a
1 changed files with 5 additions and 5 deletions

View File

@ -19,10 +19,10 @@ SETLOCAL EnableDelayedExpansion
FOR /F "tokens=1 delims=" %%A in ('git describe --tags --long') do SET current_tag=%%A
FOR /F "tokens=1 delims=" %%A in ('echo !current_tag! ^| !sed! "s/v[0-9]*\.[0-9]*-\([0-9]*\).*/\1/"') do SET commits_since_tag=%%A
call :setVersion %base_dir%\Source\Project64\version.h !commits_since_tag!
call :setVersion %base_dir%\Source\nragev20\version.h !commits_since_tag!
call :setVersion %base_dir%\Source\RSP\version.h !commits_since_tag!
call :setVersion %base_dir%\Source\Glide64\version.h !commits_since_tag!
call :setVersion "%base_dir%\Source\Project64-core\version.h" !commits_since_tag!
call :setVersion "%base_dir%\Source\nragev20\version.h" !commits_since_tag!
call :setVersion "%base_dir%\Source\RSP\version.h" !commits_since_tag!
call :setVersion "%base_dir%\Source\Glide64\version.h" !commits_since_tag!
ENDLOCAL
@ -36,7 +36,7 @@ set build_no=%~2
if exist "%out_file%" del "%out_file%"
SETLOCAL DisableDelayedExpansion
FOR /F "usebackq delims=" %%a in (`"findstr /n ^^ %version_file%"`) do (
FOR /F "usebackq delims=" %%a in (`"findstr /n ^^ "%version_file%""`) do (
set "line=%%a"
SETLOCAL EnableDelayedExpansion
set "line=!line:9999=%build_no%!"