Update Android plugin to 3.0.0

master
Moxie Marlinspike 2017-11-06 09:20:52 -08:00
parent ad6ae10a41
commit e245281b69
2 changed files with 19 additions and 11 deletions

View File

@ -6,17 +6,19 @@ buildscript {
url "https://repo1.maven.org/maven2" url "https://repo1.maven.org/maven2"
jcenter() jcenter()
} }
maven {
url 'https://maven.google.com/'
name 'Google'
}
} }
dependencies { dependencies {
classpath 'com.android.tools.build:gradle:2.3.0' classpath 'com.android.tools.build:gradle:3.0.0'
classpath files('libs/gradle-witness.jar') classpath files('libs/gradle-witness.jar')
classpath 'me.tatarka:gradle-retrolambda:3.7.0'
} }
} }
apply plugin: 'com.android.application' apply plugin: 'com.android.application'
apply plugin: 'witness' apply plugin: 'witness'
apply plugin: 'me.tatarka.retrolambda'
repositories { repositories {
maven { maven {
@ -42,6 +44,10 @@ repositories {
} }
jcenter() jcenter()
mavenLocal() mavenLocal()
maven {
url 'https://maven.google.com/'
name 'Google'
}
} }
dependencies { dependencies {
@ -81,6 +87,7 @@ dependencies {
compile 'com.melnykov:floatingactionbutton:1.3.0' compile 'com.melnykov:floatingactionbutton:1.3.0'
compile 'com.google.zxing:android-integration:3.1.0' compile 'com.google.zxing:android-integration:3.1.0'
compile 'com.squareup.dagger:dagger:1.2.2' compile 'com.squareup.dagger:dagger:1.2.2'
annotationProcessor 'com.squareup.dagger:dagger-compiler:1.2.2'
compile ("com.doomonafireball.betterpickers:library:1.5.3") { compile ("com.doomonafireball.betterpickers:library:1.5.3") {
exclude group: 'com.android.support', module: 'support-v4' exclude group: 'com.android.support', module: 'support-v4'
} }
@ -216,8 +223,9 @@ dependencyVerification {
} }
android { android {
flavorDimensions "none"
compileSdkVersion 26 compileSdkVersion 26
buildToolsVersion '25.0.2' buildToolsVersion '26.0.2'
useLibrary 'org.apache.http.legacy' useLibrary 'org.apache.http.legacy'
dexOptions { dexOptions {
@ -295,23 +303,23 @@ android {
productFlavors { productFlavors {
play { play {
dimension "none"
ext.websiteUpdateUrl = "null" ext.websiteUpdateUrl = "null"
buildConfigField "boolean", "PLAY_STORE_DISABLED", "false" buildConfigField "boolean", "PLAY_STORE_DISABLED", "false"
buildConfigField "String", "NOPLAY_UPDATE_URL", "$ext.websiteUpdateUrl" buildConfigField "String", "NOPLAY_UPDATE_URL", "$ext.websiteUpdateUrl"
} }
website { website {
dimension "none"
ext.websiteUpdateUrl = "https://updates.signal.org/android" ext.websiteUpdateUrl = "https://updates.signal.org/android"
buildConfigField "boolean", "PLAY_STORE_DISABLED", "true" buildConfigField "boolean", "PLAY_STORE_DISABLED", "true"
buildConfigField "String", "NOPLAY_UPDATE_URL", "\"$ext.websiteUpdateUrl\"" buildConfigField "String", "NOPLAY_UPDATE_URL", "\"$ext.websiteUpdateUrl\""
} }
} }
applicationVariants.all { variant -> android.applicationVariants.all { variant ->
variant.outputs.each { output -> variant.outputs.all {
output.outputFile = new File( outputFileName = outputFileName.replace(".apk", "-${variant.versionName}.apk")
output.outputFile.parent,
output.outputFile.name.replace(".apk", "-${variant.versionName}.apk"))
} }
} }

View File

@ -1,6 +1,6 @@
#Wed Oct 11 12:30:44 PDT 2017 #Mon Nov 06 08:48:17 PST 2017
distributionBase=GRADLE_USER_HOME distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-3.5.1-all.zip distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip