Skip to content

Commit 0908ba5

Browse files
committed
0.8.4402
- update to _bf_build_release.bat
1 parent ff3670d commit 0908ba5

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

tools/ccmix/_bf_build_release.bat

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,16 @@ if NOT exist %RarPath% (echo:WinRAR.exe not found&&goto bye)
1414

1515
set "verPreffix=RA2YRBF_0_8_"
1616
set "SourceDir=F:\projekty\_cnc_\RA2BruteForce\RA2BF\RA2YRBF"
17+
set "rVerPreffix=Version: 0.8."
18+
set readmeFile="%SourceDir%\README.md"
1719

1820
set /p ArchiveName=Name your release suffix (preffix is "%verPreffix%"):
1921
set "OutputArchive=%verPreffix%%ArchiveName%.zip"
2022

23+
if exist %readmeFile% (
24+
powershell -Command ^
25+
"(Get-Content '%readmeFile%') | ForEach-Object { if ($_ -like '%rVerPreffix%*') { '%rVerPreffix%%ArchiveName%' } else { $_ } } | Set-Content '%readmeFile%'"
26+
)
2127
%RarPath% a -r -ep1 "%OutputArchive%" "%SourceDir%" -z"%SourceDir%\README.md" -x"%SourceDir%\desktop.ini" -x"%SourceDir%\_build.bat" -x"%SourceDir%\MIX" -x"%SourceDir%\tools" -x"%SourceDir%\tools\ccmix" -x"%SourceDir%\.git" -x"%SourceDir%\.gitattributes" -x"%SourceDir%\.gitignore" -OS
2228

2329
echo Archive ready: %OutputArchive%
@@ -28,7 +34,7 @@ if %errorlevel% neq 1 goto bye
2834
choice /C YN /M "Do you really want to upload it as an update for autoupdater? (Y/N)"
2935
if %errorlevel% equ 1 (
3036
copy "%OutputArchive%" ra2yrbf_patch.zip /y > nul
31-
curl -T "ra2yrbf_patch.zip" -u "login:password" ftp.your.server.net
37+
curl -T "ra2yrbf_patch.zip" -u "login:password" ftp.mysite.net
3238
goto bye
3339
)
3440

0 commit comments

Comments
 (0)