Skip to content

Commit d027a29

Browse files
committed
Merge pull request Azure#1521 from yugangw-msft/mac
upload win, osx, and linux installers to azure sdk team storage account
2 parents 9df825c + 7001250 commit d027a29

File tree

1 file changed

+18
-9
lines changed

1 file changed

+18
-9
lines changed

tools/CLU/UploadOrDownloadInstaller.bat

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,28 +6,37 @@ set action=%1
66
set storageUrl=%2
77
set key=%3
88
set downloadFolder=%4
9-
set dropBaseName=ubuntu.14.04-x64
10-
set archiveFileName=%dropBaseName%.latest.tar
11-
set archive=%root%\drop\%archiveFileName%
129

1310
if "%1" == "upload" (
14-
del /Q /F %root%\drop\*.gz
15-
%~dp0\7-Zip\7z.exe a -ttar -so %archive% %root%\drop\clurun\ubuntu.14.04-x64 | %~dp0\7-Zip\7z.exe a -si %archive%.gz
11+
del /Q /F %root%\drop\*.tar.*
12+
%~dp0\7-Zip\7z.exe a -ttar -so %root%\drop\ubuntu.14.04-x64.latest.tar %root%\drop\clurun\ubuntu.14.04-x64 | %~dp0\7-Zip\7z.exe a -si %root%\drop\ubuntu.14.04-x64.latest.tar.gz
1613
if ERRORLEVEL 1 (
17-
echo failed to create tar.gz file "%archive%.gz"
14+
echo failed to create tar.gz file ubuntu.14.04-x64.latest.tar.gz
1815
exit /B 1
1916
)
20-
%~dp0\AzCopy\AzCopy.exe /Source:%root%\drop /Dest:%storageUrl% /DestKey:%key% /Pattern:%archiveFileName%.gz /Y
2117

18+
%~dp0\7-Zip\7z.exe a -ttar -so %root%\drop\win7-x64.latest.tar %root%\drop\clurun\win7-x64 | %~dp0\7-Zip\7z.exe a -si %root%\drop\win7-x64.latest.tar.gz
2219
if ERRORLEVEL 1 (
23-
echo failed to upload installers from "%root%\drop\%archiveFileName%.gz" to "%storageUrl%"
20+
echo failed to create tar.gz file win7-x64.latest.tar.gz
21+
exit /B 1
22+
)
23+
24+
%~dp0\7-Zip\7z.exe a -ttar -so %root%\drop\osx.10.10-x64.latest.tar %root%\drop\clurun\osx.10.10-x64 | %~dp0\7-Zip\7z.exe a -si %root%\drop\osx.10.10-x64.latest.tar.gz
25+
if ERRORLEVEL 1 (
26+
echo failed to create tar.gz file osx.10.10-x64.latest.tar.gz
27+
exit /B 1
28+
)
29+
30+
%~dp0\AzCopy\AzCopy.exe /Source:%root%\drop /Dest:%storageUrl% /DestKey:%key% /Pattern:*.tar.gz /Y
31+
if ERRORLEVEL 1 (
32+
echo failed to upload installers from "%root%\drop" to "%storageUrl%"
2433
exit /B 1
2534
)
2635
)
2736

2837
if "%1" == "download" (
2938
echo download the latest installer
30-
%~dp0\AzCopy\AzCopy.exe /Source:%storageUrl% /SourceKey:%key% /Dest:%downloadFolder% /Pattern:%archiveFileName%.gz /Y /S
39+
%~dp0\AzCopy\AzCopy.exe /Source:%storageUrl% /SourceKey:%key% /Dest:%downloadFolder% /Pattern:*.gz /Y /S
3140
if ERRORLEVEL 1 (
3241
echo failed to download installers from "%storageUrl%" to "%downloadFolder%"
3342
exit /B 1

0 commit comments

Comments
 (0)