diff --git a/README.md b/README.md index 54a1b44af..1103a08b3 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,11 @@ Build Status |**Debug**|[![Build Status](http://dotnet-ci.cloudapp.net/buildStatus/icon?job=Private/dotnet_cli_debug_ubuntu)](http://dotnet-ci.cloudapp.net/job/Private/job/dotnet_cli_debug_ubuntu/)|[![Build Status](http://dotnet-ci.cloudapp.net/buildStatus/icon?job=Private/dotnet_cli_debug_windows_nt)](http://dotnet-ci.cloudapp.net/job/Private/job/dotnet_cli_debug_windows_nt/)|[![Build Status](http://dotnet-ci.cloudapp.net/buildStatus/icon?job=Private/dotnet_cli_debug_osx)](http://dotnet-ci.cloudapp.net/job/Private/job/dotnet_cli_debug_osx/) | |**Release**|[![Build Status](http://dotnet-ci.cloudapp.net/buildStatus/icon?job=Private/dotnet_cli_release_ubuntu)](http://dotnet-ci.cloudapp.net/job/Private/job/dotnet_cli_release_ubuntu/)|[![Build Status](http://dotnet-ci.cloudapp.net/buildStatus/icon?job=Private/dotnet_cli_release_windows_nt)](http://dotnet-ci.cloudapp.net/job/Private/job/dotnet_cli_release_windows_nt/)|[![Build Status](http://dotnet-ci.cloudapp.net/buildStatus/icon?job=Private/dotnet_cli_release_osx)](http://dotnet-ci.cloudapp.net/job/Private/job/dotnet_cli_release_osx/) | +| |Ubuntu 14.04 |Windows |Mac OS X | +|---------|:------:|:------:|:------:| +|**Installers**|[Download Debian Package](https://dotnetcli.blob.core.windows.net/dotnet/dev/Installers/Latest/dotnet-linux-x64.latest.deb)|[Download Msi](https://dotnetcli.blob.core.windows.net/dotnet/dev/Installers/Latest/dotnet-win-x64.latest.msi)|[Download Pkg](https://dotnetcli.blob.core.windows.net/dotnet/dev/Installers/Latest/dotnet-osx-x64.latest.pkg) | +|**Binaries**|[Download tar file](https://dotnetcli.blob.core.windows.net/dotnet/dev/Binaries/Latest/dotnet-linux-x64.latest.tar.gz)|[Download zip file](https://dotnetcli.blob.core.windows.net/dotnet/dev/Binaries/Latest/dotnet-win-x64.latest.zip)|[Download tar file](https://dotnetcli.blob.core.windows.net/dotnet/dev/Binaries/Latest/dotnet-osx-x64.latest.tar.gz) | + ## Prerequisites In order to build dotnet-cli, you need the following installed on you machine diff --git a/scripts/publish.ps1 b/scripts/publish.ps1 index 1a173db15..cd5c6be71 100644 --- a/scripts/publish.ps1 +++ b/scripts/publish.ps1 @@ -60,37 +60,55 @@ function UploadBinaries($zipFile) $fileName = [System.IO.Path]::GetFileName($zipFile) $Upload_URI = "https://$env:STORAGE_ACCOUNT.blob.core.windows.net/$env:STORAGE_CONTAINER/$env:CHANNEL/Binaries/$env:DOTNET_BUILD_VERSION/$fileName$env:SASTOKEN" - if(UploadFile $Upload_URI $zipFile) + if(-Not (UploadFile $Upload_URI $zipFile)) { - # update the index file too - $indexContent = "Binaries/$env:DOTNET_BUILD_VERSION/$fileName" - $indexFile = "$env:TEMP\latest.win.index" - $indexContent | Out-File -FilePath $indexFile - - # upload the index file - $Upload_URI = "https://$env:STORAGE_ACCOUNT.blob.core.windows.net/$env:STORAGE_CONTAINER/$env:CHANNEL/dnvm/latest.win.index$env:SASTOKEN" - - if(UploadFile $Upload_URI $indexFile) - { - $result = 0 - } + return -1 } - return $result + Write-Host "Updating the latest dotnet binaries for windows.." + $Upload_URI_Latest = "https://$env:STORAGE_ACCOUNT.blob.core.windows.net/$env:STORAGE_CONTAINER/$env:CHANNEL/Binaries/Latest/dotnet-win-x64.latest.zip$env:SASTOKEN" + + if(-Not (UploadFile $Upload_URI_Latest $zipFile)) + { + return -1 + } + + + # update the index file too + $indexContent = "Binaries/$env:DOTNET_BUILD_VERSION/$fileName" + $indexFile = "$env:TEMP\latest.win.index" + $indexContent | Out-File -FilePath $indexFile + + # upload the index file + $Upload_URI = "https://$env:STORAGE_ACCOUNT.blob.core.windows.net/$env:STORAGE_CONTAINER/$env:CHANNEL/dnvm/latest.win.index$env:SASTOKEN" + + if(-Not (UploadFile $Upload_URI $indexFile)) + { + return -1 + } + + return 0 } function UploadInstallers($msiFile) { - $result = -1 $fileName = [System.IO.Path]::GetFileName($msiFile) $Upload_URI = "https://$env:STORAGE_ACCOUNT.blob.core.windows.net/$env:STORAGE_CONTAINER/$env:CHANNEL/Installers/$env:DOTNET_BUILD_VERSION/$fileName$env:SASTOKEN" - if(UploadFile $Upload_URI $msiFile) + if(-Not (UploadFile $Upload_URI $msiFile)) { - $result = 0 + return -1 } - return $result + Write-Host "Updating the latest dotnet installer for windows.." + $Upload_URI_Latest = "https://$env:STORAGE_ACCOUNT.blob.core.windows.net/$env:STORAGE_CONTAINER/$env:CHANNEL/Installers/Latest/dotnet-win-x64.latest.msi$env:SASTOKEN" + + if(-Not (UploadFile $Upload_URI_Latest $msiFile)) + { + return -1 + } + + return 0 } if(!(CheckRequiredVariables)) diff --git a/scripts/publish.sh b/scripts/publish.sh index 63c2762f4..b21c45653 100755 --- a/scripts/publish.sh +++ b/scripts/publish.sh @@ -124,16 +124,24 @@ upload_binaries_to_blob_storage(){ local filename=$(basename $tarfile) local blob="$CHANNEL/Binaries/$DOTNET_BUILD_VERSION/$filename" - if upload_file_to_blob_storage_azure_cli $blob $tarfile; then - # update the index file - local indexContent="Binaries/$DOTNET_BUILD_VERSION/$filename" - local indexfile="latest.$OSNAME.index" - local update_URL="https://$STORAGE_ACCOUNT.blob.core.windows.net/$STORAGE_CONTAINER/$CHANNEL/dnvm/$indexfile$SASTOKEN" - update_file_in_blob_storage $update_URL $indexfile $indexContent - return $? + if ! upload_file_to_blob_storage_azure_cli $blob $tarfile; then + return 1 fi - return 1 + # create the latest blob + echo "Updating the latest dotnet binaries.." + local latestblob="$CHANNEL/Binaries/Latest/dotnet-$OSNAME-x64.latest.tar.gz" + + if ! upload_file_to_blob_storage_azure_cli $latestblob $tarfile; then + return 1 + fi + + # update the index file + local indexContent="Binaries/$DOTNET_BUILD_VERSION/$filename" + local indexfile="latest.$OSNAME.index" + local update_URL="https://$STORAGE_ACCOUNT.blob.core.windows.net/$STORAGE_CONTAINER/$CHANNEL/dnvm/$indexfile$SASTOKEN" + update_file_in_blob_storage $update_URL $indexfile $indexContent + return $? } upload_installers_to_blob_storage(){ @@ -145,6 +153,15 @@ upload_installers_to_blob_storage(){ return 1 fi + # create the latest blob + echo "Updating the latest dotnet installer.." + local extension="${filename##*.}" + local latestblob="$CHANNEL/Installers/Latest/dotnet-$OSNAME-x64.latest.$extension" + + if ! upload_file_to_blob_storage_azure_cli $latestblob $installfile; then + return 1 + fi + # debain packages need to be uploaded to the PPA feed too if [[ $installfile == *.deb ]]; then DEB_FILE=$installfile