chore: release Android Studio 0.3.2 Build 132

- Fix a real dumb bug in the installer that didn't run if Android Studio
   wasn't previously installed
This commit is contained in:
Iristyle
2014-01-03 12:18:34 -05:00
parent b13f5dcbf9
commit 7d5a987944
2 changed files with 15 additions and 13 deletions

View File

@@ -3,7 +3,7 @@
<metadata>
<id>AndroidStudio</id>
<title>Android Studio</title>
<version>0.2.130.737825</version>
<version>0.3.2.132893413</version>
<authors>Google</authors>
<owners>Ethan J Brown</owners>
<summary>Android Studio is a new Android development environment based on IntelliJ IDEA.</summary>

View File

@@ -1,5 +1,6 @@
$package = 'AndroidStudio'
$version = 130.737825
$majorVersion = '0.3.2'
$buildVersion = 132.893413
try {
@@ -8,27 +9,28 @@ try {
if ((Test-Path $build) -and ((Get-Content $build) -match '.*?(\d+\.\d+)'))
{
$installedVersion = [decimal]$Matches[1]
if ($installedVersion -lt $version)
if ($installedVersion -lt $buildVersion)
{
Write-Host "Uninstalling existing version $installedVersion"
. .\chocolateyUninstall.ps1
$params = @{
PackageName = $package;
FileType = 'exe';
#uses NSIS installer - http://nsis.sourceforge.net/Docs/Chapter3.html
SilentArgs = '/S';
Url = 'http://dl.google.com/android/studio/android-studio-bundle-130.737825-windows.exe';
}
Install-ChocolateyPackage @params
}
else
{
Write-Host "$package $installedVersion already installed!"
exit
}
}
$params = @{
PackageName = $package;
FileType = 'exe';
#uses NSIS installer - http://nsis.sourceforge.net/Docs/Chapter3.html
SilentArgs = '/S';
Url = "https://dl.google.com/android/studio/install/$majorVersion/android-studio-bundle-$buildVersion-windows.exe";
}
Install-ChocolateyPackage @params
Write-ChocolateySuccess $package
} catch {
Write-ChocolateyFailure $package "$($_.Exception.Message)"