-
Notifications
You must be signed in to change notification settings - Fork 10
/
makenuget.bat
23 lines (18 loc) · 1.55 KB
/
makenuget.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
set baseurl=
set nmakecmd=gdal-nuget GDAL_RELEASE_VER=%gdal-release-ver%
set cmdname=Creating nuget packages
for /f "tokens=1-7 delims=:.,- " %%a in ("%date% %time%") do set id=%%a%%b%%c-%%d-%%e-%%f-%%g-%logid%
echo %date% %time%: %cmdname% started ^ ^<a href="%baseurl%%compiler%-%id%.txt"^>stdout^</a^>^ ^<a href="%baseurl%%compiler%-%id%-err.txt"^>stderr^</a^>^  >>C:\Inetpub\wwwroot\sdk\build-output\%logid%.html
echo ^<span style="background-color:Yellow;color:Black;font-weight:bold"^>%cmdname%^</span^> >C:\Inetpub\wwwroot\sdk\build-output\status-%logid%.html
nmake %nmakecmd% >C:\Inetpub\wwwroot\sdk\build-output\%compiler%-%id%.txt 2>C:\Inetpub\wwwroot\sdk\build-output\%compiler%-%id%-err.txt
IF ERRORLEVEL 1 (
echo ^<span style="background-color:Red;color:Black;font-weight:bold"^>%cmdname% Failed^</span^> >C:\Inetpub\wwwroot\sdk\build-output\status-%logid%.html
echo ^<span style="background-color:Red;color:Black;font-weight:bold"^>Failed^</span^>^<br/^> >>C:\Inetpub\wwwroot\sdk\build-output\%logid%.html
@goto exit
) else (
echo ^<span style="background-color:Lime;color:Black;font-weight:bold"^>%cmdname% OK^</span^> >C:\Inetpub\wwwroot\sdk\build-output\status-%logid%.html
echo ^<span style="background-color:Lime;color:Black;font-weight:bold"^>Success^</span^>^<br/^> >>C:\Inetpub\wwwroot\sdk\build-output\%logid%.html
)
echo ^<span style="background-color:Lime;color:Black;font-weight:bold"^>finished on %date% %time%^</span^> >C:\Inetpub\wwwroot\sdk\build-output\status-%logid%.html
:exit
echo ^<hr/^> >>C:\Inetpub\wwwroot\sdk\build-output\%logid%.html