diff --git a/build.gradle b/build.gradle index 82e8824a86..595d3c0649 100644 --- a/build.gradle +++ b/build.gradle @@ -1,16 +1,15 @@ -import java.security.MessageDigest - buildscript { - ext.kotlin_version = "1.3.31" + ext.kotlin_version = "1.4.0" ext.kovenant_version = "3.3.0" repositories { mavenLocal() google() mavenCentral() + jcenter() } dependencies { - classpath "com.android.tools.build:gradle:3.4.1" + classpath "com.android.tools.build:gradle:4.0.1" classpath files('libs/gradle-witness.jar') classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" classpath "com.google.gms:google-services:4.3.3" @@ -18,8 +17,8 @@ buildscript { } apply plugin: 'com.android.application' -apply plugin: 'kotlin-android-extensions' apply plugin: 'kotlin-android' +apply plugin: 'kotlin-android-extensions' apply plugin: 'witness' apply plugin: 'kotlin-kapt' apply plugin: 'com.google.gms.google-services' @@ -73,14 +72,14 @@ configurations.all { dependencies { implementation 'androidx.appcompat:appcompat:1.2.0' implementation 'androidx.recyclerview:recyclerview:1.1.0' - implementation 'com.google.android.material:material:1.2.0' + implementation 'com.google.android.material:material:1.2.1' implementation 'androidx.legacy:legacy-support-v13:1.0.0' implementation 'androidx.cardview:cardview:1.0.0' implementation 'androidx.preference:preference:1.1.1' implementation 'androidx.legacy:legacy-preference-v14:1.0.0' implementation 'androidx.gridlayout:gridlayout:1.0.0' implementation 'androidx.exifinterface:exifinterface:1.2.0' - implementation 'androidx.constraintlayout:constraintlayout:1.1.3' + implementation 'androidx.constraintlayout:constraintlayout:2.0.1' implementation 'androidx.multidex:multidex:2.0.1' implementation 'androidx.lifecycle:lifecycle-extensions:2.2.0' implementation 'androidx.lifecycle:lifecycle-common-java8:2.2.0' @@ -90,7 +89,6 @@ dependencies { exclude group: 'com.google.firebase', module: 'firebase-analytics' exclude group: 'com.google.firebase', module: 'firebase-measurement-connector' } - implementation 'com.google.android.exoplayer:exoplayer-core:2.9.1' implementation 'com.google.android.exoplayer:exoplayer-ui:2.9.1' implementation 'org.conscrypt:conscrypt-android:2.0.0' @@ -108,7 +106,7 @@ dependencies { implementation 'com.pnikosis:materialish-progress:1.5' implementation 'org.greenrobot:eventbus:3.0.0' implementation 'pl.tajchert:waitingdots:0.1.0' - implementation 'com.theartofdev.edmodo:android-image-cropper:2.7.0' + implementation 'com.theartofdev.edmodo:android-image-cropper:2.8.0' implementation 'com.melnykov:floatingactionbutton:1.3.0' implementation 'com.google.zxing:android-integration:3.1.0' implementation 'com.squareup.dagger:dagger:1.2.2' @@ -142,30 +140,6 @@ dependencies { exclude group: 'com.fasterxml.jackson.core' exclude group: 'org.freemarker' } - - testImplementation 'junit:junit:4.12' - testImplementation 'org.assertj:assertj-core:3.11.1' - testImplementation 'org.mockito:mockito-core:1.9.5' - testImplementation 'org.powermock:powermock-api-mockito:1.6.1' - testImplementation 'org.powermock:powermock-module-junit4:1.6.1' - testImplementation 'org.powermock:powermock-module-junit4-rule:1.6.1' - testImplementation 'org.powermock:powermock-classloading-xstream:1.6.1' - - testImplementation 'androidx.test:core:1.3.0-rc03' - androidTestImplementation 'androidx.multidex:multidex:2.0.1' - androidTestImplementation 'androidx.multidex:multidex-instrumentation:2.0.0' - androidTestImplementation 'com.google.dexmaker:dexmaker:1.2' - androidTestImplementation 'com.google.dexmaker:dexmaker-mockito:1.2' - androidTestImplementation ('org.assertj:assertj-core:1.7.1') { - exclude group: 'org.hamcrest', module: 'hamcrest-core' - } - androidTestImplementation ('com.squareup.assertj:assertj-android:1.1.1') { - exclude group: 'org.hamcrest', module: 'hamcrest-core' - exclude group: 'com.android.support', module: 'support-annotations' - } - testImplementation 'org.robolectric:robolectric:4.2' - testImplementation 'org.robolectric:shadows-multidex:4.2' - // Loki // Local: implementation "org.whispersystems:signal-service-android:2.13.2" // Run ./gradlew install from session-android-service to install @@ -183,6 +157,28 @@ dependencies { implementation "com.github.tbruyelle:rxpermissions:0.10.2" implementation "com.github.ybq:Android-SpinKit:1.4.0" implementation "com.opencsv:opencsv:4.6" + + testImplementation 'junit:junit:4.12' + testImplementation 'org.assertj:assertj-core:3.11.1' + testImplementation 'org.mockito:mockito-core:1.9.5' + testImplementation 'org.powermock:powermock-api-mockito:1.6.1' + testImplementation 'org.powermock:powermock-module-junit4:1.6.1' + testImplementation 'org.powermock:powermock-module-junit4-rule:1.6.1' + testImplementation 'org.powermock:powermock-classloading-xstream:1.6.1' + testImplementation 'androidx.test:core:1.3.0' + androidTestImplementation 'androidx.multidex:multidex:2.0.1' + androidTestImplementation 'androidx.multidex:multidex-instrumentation:2.0.0' + androidTestImplementation 'com.google.dexmaker:dexmaker:1.2' + androidTestImplementation 'com.google.dexmaker:dexmaker-mockito:1.2' + androidTestImplementation ('org.assertj:assertj-core:1.7.1') { + exclude group: 'org.hamcrest', module: 'hamcrest-core' + } + androidTestImplementation ('com.squareup.assertj:assertj-android:1.1.1') { + exclude group: 'org.hamcrest', module: 'hamcrest-core' + exclude group: 'com.android.support', module: 'support-annotations' + } + testImplementation 'org.robolectric:robolectric:4.2' + testImplementation 'org.robolectric:shadows-multidex:4.2' } def canonicalVersionCode = 87 @@ -211,10 +207,10 @@ android { minSdkVersion 21 targetSdkVersion 29 - multiDexEnabled true + multiDexEnabled true // Even though we're running API 21+, this is still needed for release builds vectorDrawables.useSupportLibrary = true - project.ext.set("archivesBaseName", "Signal") + project.ext.set("archivesBaseName", "session") buildConfigField "long", "BUILD_TIMESTAMP", getLastCommitTimestamp() + "L" buildConfigField "String", "SIGNAL_URL", "\"\"" @@ -283,7 +279,7 @@ android { 'proguard-ez-vcard.pro', 'proguard.cfg' testProguardFiles 'proguard-automation.pro', - 'proguard.cfg' + 'proguard.cfg' } release { minifyEnabled true @@ -353,6 +349,7 @@ android { } } +/* def assembleWebsiteDescriptor = { variant, file -> if (file.exists()) { MessageDigest md = MessageDigest.getInstance("SHA-256") @@ -376,7 +373,7 @@ def assembleWebsiteDescriptor = { variant, file -> descriptorFile.write(descriptor) } } -/* + def signProductionRelease = { variant -> variant.outputs.collect { output -> String apkName = output.outputFile.name diff --git a/buildSrc/build.gradle b/buildSrc/build.gradle index 889ee1d68a..f05084afb7 100644 --- a/buildSrc/build.gradle +++ b/buildSrc/build.gradle @@ -5,5 +5,5 @@ repositories { } dependencies { - compile 'com.android.tools.build:apksig:3.3.2' + implementation 'com.android.tools.build:apksig:4.0.1' } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 1b2b07cfb0..33682bbbf9 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-5.2.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.6.1-all.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists