aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2014-12-09 20:14:56 +0100
committerDaniel Gultsch <daniel@gultsch.de>2014-12-09 20:14:56 +0100
commit135563e941a39aa04b0657219cb5bb47fb639d9b (patch)
tree1ed1073bed9ead0f34f1a2e3ff63cda91fd7edb2
parent16e3c07cf116bb4d61a3d30a3841576523e7dbc2 (diff)
parent338fd9e7b3d4661ca132b6074e2168223f65eb0c (diff)
Merge pull request #768 from betheg/as
gradle: fix Cannot set property outputFile on null object.
-rw-r--r--build.gradle4
1 files changed, 3 insertions, 1 deletions
diff --git a/build.gradle b/build.gradle
index 51327d458..e7cb10979 100644
--- a/build.gradle
+++ b/build.gradle
@@ -84,7 +84,9 @@ android {
applicationVariants.all { variant ->
if (variant.name.equals('release')) {
variant.outputs.each { output ->
- output.zipAlign.outputFile = new File(output.outputFile.parent, rootProject.name + "-${variant.versionName}.apk")
+ 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"))
}