diff options
Diffstat (limited to 'build.gradle')
-rw-r--r-- | build.gradle | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/build.gradle b/build.gradle index 4a172eeb..e7cb1097 100644 --- a/build.gradle +++ b/build.gradle @@ -6,7 +6,7 @@ buildscript { mavenCentral() } dependencies { - classpath 'com.android.tools.build:gradle:0.12.2' + classpath 'com.android.tools.build:gradle:1.0.0' } } @@ -46,8 +46,8 @@ android { defaultConfig { minSdkVersion 14 targetSdkVersion 19 - versionCode 39 - versionName "0.9.2" + versionCode 40 + versionName "0.9.3" } compileOptions { @@ -81,18 +81,15 @@ android { buildTypes.release.signingConfig = null } - buildTypes { - applicationVariants.all { variant -> - def fileName = variant.packageApplication.outputFile.name.replace(".apk", - "-" + defaultConfig.versionName + ".apk") - variant.packageApplication.outputFile = new - File(variant.packageApplication.outputFile.parent, fileName) - if (variant.zipAlign) { - if (variant.name.equals('release')) { - variant.outputFile = new File(variant.outputFile.parent, - rootProject.name + "-" + defaultConfig.versionName + ".apk") - } + applicationVariants.all { variant -> + if (variant.name.equals('release')) { + variant.outputs.each { output -> + if (output.zipAlign != null) { + output.zipAlign.outputFile = new File(output.outputFile.parent, rootProject.name + "-${variant.versionName}.apk") } + output.packageApplication.outputFile = new File(output.outputFile.parent, output.packageApplication.outputFile.name + .replace(".apk", "-${variant.versionName}.apk")) + } } } |