zcash-android-wallet/app/build.gradle

172 lines
6.1 KiB
Groovy
Raw Normal View History

2019-11-26 12:29:16 -08:00
import cash.z.ecc.android.Deps
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'kotlin-kapt'
apply plugin: 'com.google.gms.google-services'
2019-11-26 12:29:16 -08:00
//apply plugin: 'com.github.ben-manes.versions'
archivesBaseName = 'zcash-android-wallet'
group = 'cash.z.ecc.android'
2020-08-28 01:06:12 -07:00
version = '1.0.0-alpha34'
2019-11-26 12:29:16 -08:00
android {
ndkVersion "21.1.6352462"
2019-11-26 12:29:16 -08:00
compileSdkVersion Deps.compileSdkVersion
buildToolsVersion Deps.buildToolsVersion
viewBinding.enabled = true
defaultConfig {
applicationId 'cash.z.ecc.android'
minSdkVersion Deps.minSdkVersion
targetSdkVersion Deps.targetSdkVersion
2020-08-28 01:06:12 -07:00
versionCode = 1_00_00_034
// last digits are alpha(0XX) beta(2XX) rc(4XX) release(8XX) dev(9XX). Ex: 1_08_04_401 is an release candidate build of version 1.8.4 and 1_08_04_800 would be the final release.
2019-11-26 12:29:16 -08:00
versionName = "$version"
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
testInstrumentationRunnerArguments clearPackageData: 'true'
multiDexEnabled true
resValue 'string', 'bugsnag_api_key', "${(project.findProperty('BUGSNAG_API_KEY') ?: System.getenv('BUGSNAG_API_KEY')) ?: ''}"
// this setting allows using color resources in vector drawables, rather than hardcoded values (note: only works when minApi is 21)
// per https://google.github.io/android-gradle-dsl/current/com.android.build.gradle.internal.dsl.VectorDrawablesOptions.html: If set to an empty collection, all special handling of vector drawables will be disabled.
vectorDrawables.generatedDensities = []
2019-11-26 12:29:16 -08:00
}
flavorDimensions 'network'
productFlavors {
// would rather name them "testnet" and "mainnet" but product flavor names cannot start with the word "test"
zcashtestnet {
dimension 'network'
applicationId 'cash.z.ecc.android.testnet'
matchingFallbacks = ['zcashtestnet', 'debug']
}
zcashmainnet {
dimension 'network'
matchingFallbacks = ['zcashmainnet', 'release']
}
}
signingConfigs {
placeholder {
storeFile file("${rootProject.projectDir}/placeholder.keystore")
keyAlias "androiddebugkey"
keyPassword "android"
storePassword "android"
}
}
2019-11-26 12:29:16 -08:00
buildTypes {
release {
minifyEnabled false
shrinkResources false
2019-11-26 12:29:16 -08:00
useProguard false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.placeholder
2019-11-26 12:29:16 -08:00
}
debug {
minifyEnabled false
shrinkResources false
2019-11-26 12:29:16 -08:00
useProguard false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
// mock {
// initWith debug
// matchingFallbacks = ['debug', 'release', 'zcashtestnet']
// }
}
2019-11-26 12:29:16 -08:00
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = "1.8"
}
kapt {
arguments {
arg 'dagger.fastInit', 'enabled'
arg 'dagger.fullBindingGraphValidation', 'ERROR'
arg 'dagger.gradle.incremental'
}
}
2020-09-25 08:50:20 -07:00
packagingOptions {
exclude 'META-INF/AL2.0'
exclude 'META-INF/LGPL2.1'
}
2019-12-18 10:24:06 -08:00
applicationVariants.all { variant ->
variant.outputs.all {
outputFileName = "$archivesBaseName-v${defaultConfig.versionName}-${variant.buildType.name}.apk"
}
}
2019-11-26 12:29:16 -08:00
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation project(':qrecycler')
implementation project(':feedback')
implementation project(':mnemonic')
implementation project(':lockbox')
2019-11-26 12:29:16 -08:00
2020-02-12 05:03:14 -08:00
// Zcash
implementation Deps.Zcash.ANDROID_WALLET_PLUGINS
zcashtestnetImplementation Deps.Zcash.Sdk.TESTNET
zcashmainnetImplementation Deps.Zcash.Sdk.MAINNET
2019-11-26 12:29:16 -08:00
// Kotlin
implementation Deps.Kotlin.STDLIB
// Android
implementation Deps.AndroidX.ANNOTATION
2019-11-26 12:29:16 -08:00
implementation Deps.AndroidX.APPCOMPAT
implementation Deps.AndroidX.BIOMETRICS
2019-11-26 12:29:16 -08:00
implementation Deps.AndroidX.CONSTRAINT_LAYOUT
implementation Deps.AndroidX.CORE_KTX
implementation Deps.AndroidX.FRAGMENT_KTX
implementation Deps.AndroidX.LEGACY
implementation Deps.AndroidX.PAGING
implementation Deps.AndroidX.RECYCLER
implementation Deps.AndroidX.CameraX.CAMERA2
implementation Deps.AndroidX.CameraX.CORE
implementation Deps.AndroidX.CameraX.LIFECYCLE
implementation Deps.AndroidX.CameraX.View.EXT
implementation Deps.AndroidX.CameraX.View.VIEW
implementation Deps.AndroidX.Lifecycle.LIFECYCLE_EXTENSIONS
implementation Deps.AndroidX.Lifecycle.LIFECYCLE_RUNTIME_KTX
2019-11-26 12:29:16 -08:00
implementation Deps.AndroidX.Navigation.FRAGMENT_KTX
implementation Deps.AndroidX.Navigation.UI_KTX
implementation Deps.AndroidX.Room.ROOM_KTX
kapt Deps.AndroidX.Room.ROOM_COMPILER
2019-11-26 12:29:16 -08:00
// Google
implementation Deps.Google.GUAVA
2019-11-26 12:29:16 -08:00
implementation Deps.Google.MATERIAL
implementation Deps.Google.ML_VISION // QR Scanner
2019-11-26 12:29:16 -08:00
// Dagger
implementation Deps.Dagger.ANDROID_SUPPORT
kapt Deps.Dagger.ANDROID_PROCESSOR
kapt Deps.Dagger.COMPILER
// grpc-java
implementation Deps.Grpc.ANDROID
implementation Deps.Grpc.OKHTTP
implementation Deps.Grpc.PROTOBUG
implementation Deps.Grpc.STUB
implementation Deps.JavaX.JAVA_ANNOTATION
// Analytics (for dogfooding/crash-reporting/feedback only on internal team builds)
implementation Deps.Analytics.MIXPANEL
implementation Deps.Analytics.BUGSNAG
2020-01-13 16:09:22 -08:00
// Misc.
implementation Deps.Misc.LOTTIE
implementation Deps.Misc.CHIPS
2020-01-13 16:09:22 -08:00
2019-11-26 12:29:16 -08:00
// Tests
testImplementation Deps.Test.COROUTINES_TEST
2019-11-26 12:29:16 -08:00
testImplementation Deps.Test.JUNIT
testImplementation Deps.Test.MOKITO
2019-11-26 12:29:16 -08:00
androidTestImplementation Deps.Test.Android.JUNIT
androidTestImplementation Deps.Test.Android.ESPRESSO
}
defaultTasks 'clean', 'installZcashmainnetRelease'