| /* |
| * SPDX-FileCopyrightText: 2020 The Calyx Institute |
| * SPDX-License-Identifier: Apache-2.0 |
| */ |
| |
| plugins { |
| id 'com.android.application' |
| id 'org.jetbrains.kotlin.android' |
| } |
| |
| android { |
| namespace 'org.calyxos.backup.contacts' |
| compileSdk rootProject.ext.compileSdk |
| |
| defaultConfig { |
| applicationId "org.calyxos.backup.contacts" |
| minSdk rootProject.ext.minSdk |
| targetSdk rootProject.ext.targetSdk |
| |
| testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" |
| testInstrumentationRunnerArguments disableAnalytics: 'true' |
| } |
| |
| compileOptions { |
| sourceCompatibility = JavaVersion.VERSION_17 |
| targetCompatibility = JavaVersion.VERSION_17 |
| } |
| |
| kotlinOptions { |
| jvmTarget = JavaVersion.VERSION_17.toString() |
| } |
| |
| packagingOptions { |
| exclude("META-INF/LICENSE.md") |
| exclude("META-INF/LICENSE-notice.md") |
| } |
| |
| testOptions { |
| unitTests.returnDefaultValues = true |
| } |
| |
| // optional signingConfigs |
| // On userdebug builds, you can use the testkey here to update the system app |
| def keystorePropertiesFile = project.file("keystore.properties") |
| if (keystorePropertiesFile.exists()) { |
| def keystoreProperties = new Properties() |
| keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) |
| |
| signingConfigs { |
| release { |
| keyAlias keystoreProperties['keyAlias'] |
| keyPassword keystoreProperties['keyPassword'] |
| storeFile file(keystoreProperties['storeFile']) |
| storePassword keystoreProperties['storePassword'] |
| } |
| } |
| buildTypes.release.signingConfig = signingConfigs.release |
| buildTypes.debug.signingConfig = signingConfigs.release |
| } |
| } |
| |
| def aospDeps = fileTree(include: [ |
| // out/target/common/obj/JAVA_LIBRARIES/com.android.vcard_intermediates/classes.jar |
| 'com.android.vcard.jar' |
| ], dir: 'libs') |
| |
| dependencies { |
| implementation aospDeps |
| |
| testImplementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" |
| testImplementation "junit:junit:$junit4_version" |
| testImplementation "io.mockk:mockk:$mockk_version" |
| |
| androidTestImplementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" |
| androidTestImplementation 'androidx.test.ext:junit:1.1.5' |
| androidTestImplementation "androidx.test.espresso:espresso-core:$espresso_version" |
| androidTestImplementation "io.mockk:mockk-android:$mockk_version" |
| } |