secant-android-wallet/settings.gradle.kts

288 lines
15 KiB
Plaintext
Raw Normal View History

enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")
pluginManagement {
repositories {
val isRepoRestrictionEnabled = true
mavenCentral {
if (isRepoRestrictionEnabled) {
content {
includeGroup("wtf.emulator")
}
}
}
google {
if (isRepoRestrictionEnabled) {
content {
includeGroup("androidx.navigation")
includeGroup("com.android.tools")
includeGroup("com.google.testing.platform")
includeGroupByRegex("androidx.*")
includeGroupByRegex("com\\.android.*")
includeGroupByRegex("com\\.android\\.tools.*")
}
}
}
gradlePluginPortal {
if (isRepoRestrictionEnabled) {
content {
excludeGroup("androidx.navigation")
excludeGroup("com.android.tools")
excludeGroup("com.google.testing.platform")
excludeGroupByRegex("androidx.*")
excludeGroupByRegex("com\\.android.*")
excludeGroupByRegex("com\\.android\\.tools.*")
}
}
}
}
plugins {
val androidGradlePluginVersion = extra["ANDROID_GRADLE_PLUGIN_VERSION"].toString()
val emulatorWtfGradlePluginVersion = extra["EMULATOR_WTF_GRADLE_PLUGIN_VERSION"].toString()
val detektVersion = extra["DETEKT_VERSION"].toString()
2022-04-04 06:37:00 -07:00
val fulladleVersion = extra["FULLADLE_VERSION"].toString()
val gradleVersionsPluginVersion = extra["GRADLE_VERSIONS_PLUGIN_VERSION"].toString()
val kotlinVersion = extra["KOTLIN_VERSION"].toString()
2022-04-04 06:37:00 -07:00
val playPublisherVersion = extra["PLAY_PUBLISHER_PLUGIN_VERSION"].toString()
id("com.android.application") version (androidGradlePluginVersion) apply (false)
id("com.android.library") version (androidGradlePluginVersion) apply (false)
id("com.github.ben-manes.versions") version (gradleVersionsPluginVersion) apply (false)
id("com.github.triplet.play") version (playPublisherVersion) apply (false)
2022-01-26 12:13:19 -08:00
id("com.osacky.fulladle") version (fulladleVersion) apply (false)
id("io.gitlab.arturbosch.detekt") version (detektVersion) apply (false)
id("wtf.emulator.gradle") version (emulatorWtfGradlePluginVersion) apply (false)
kotlin("android") version (kotlinVersion) apply (false)
kotlin("jvm") version (kotlinVersion)
kotlin("multiplatform") version (kotlinVersion)
}
}
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
@Suppress("UnstableApiUsage")
repositories {
val isRepoRestrictionEnabled = true
2022-01-26 12:13:19 -08:00
google {
if (isRepoRestrictionEnabled) {
content {
includeGroup("android.arch.core")
includeGroup("android.arch.lifecycle")
includeGroup("com.google.android.material")
includeGroup("com.google.testing.platform")
includeGroup("com.google.android.play")
includeGroupByRegex("androidx.*")
includeGroupByRegex("com\\.android.*")
}
}
}
2022-01-26 12:13:19 -08:00
mavenCentral {
if (isRepoRestrictionEnabled) {
content {
excludeGroup("android.arch.lifecycle")
excludeGroup("android.arch.core")
excludeGroup("wtf.emulator")
excludeGroup("com.google.android.material")
excludeGroup("com.google.android.play")
excludeGroupByRegex("androidx.*")
excludeGroupByRegex("com\\.android.*")
}
}
}
maven("https://oss.sonatype.org/content/repositories/snapshots") {
2022-05-31 11:28:33 -07:00
mavenContent {
snapshotsOnly()
}
if (isRepoRestrictionEnabled) {
content {
includeGroup("cash.z.ecc.android")
}
}
}
maven("https://maven.emulator.wtf/releases/") {
if (isRepoRestrictionEnabled) {
content {
includeGroup("wtf.emulator")
}
}
}
}
@Suppress("UnstableApiUsage", "MaxLineLength")
versionCatalogs {
create("libs") {
[#313] scan qr screen functional * [#312] [#309] Scaffold Scan QR Screen - Screen scaffolding. - Model classes. - Screen states handling. - Needed dependencies added. - Camera permission handling. Redirect to Settings. - Added SettingsUtilTest class. - Added view classes tests. - Renamed tag class in update package. - Fix the scan frame size while changing the screen orientation. - Use local variable for cameraProvider. - Use UUID for source of randomness. - Eliminate blocking call for camera. - Fix preview name. - Remove Google Guava dependency. - Suppress Lint warning. - Improved calculation of the camera frame size. Moved it into Constraint layout. - Added custom image analyser class. - Implemented logic for the QR scan screen while QR code is found. - Manual tests added. - New module with integration tests for QR Scan screen. Added 3 integration and 4 view tests. - Simplify QR Scan screen view basic tests. - Switched from pure compose permission handling to Accompanist way of handling CAMERA permission. - Added validation of Zcash wallet address from QR scanning result. - Fix the integration tests for the CI WTF emulator runs. - Add comment on RTL test result. - Improve waitForDeviceIdle() method. Use it on the other test too. - Change the integration test module main manifest package name. - Debounce scans. - Improve thread safety of scan collection. - Added instructions on how to set up an emulator in manual tests. - Replace compose collectAsState() with coroutine launch(). - Add sample() to get rid of several callback events at the same time. - Stop updating the scanState when it's already in Scanning state. - Fix condition on navigation. - Remove validateJob check. - Speed up the integration test - Wrap ImageAnalysis.qrCodeFlow to remember. - Auto-close the camera image when we're done with it in all cases. - Update minimal SDK version to 24 for WTF emulators. - Update Architecture documentation. - Removed extra blank space in ui-design module definition. - Add ui-integration-test-lib. - Update Mermaid diagram with newly added module. - Move UI modules into one wrap in the diagram. - Move sdk-ext-lib and sdk-ext-ui under the same modules section. - Update camera dependencies. Co-authored-by: Carter Jernigan <git@carterjernigan.com>
2022-06-02 04:35:51 -07:00
val accompanistPermissionsVersion = extra["ACCOMPANIST_PERMISSIONS_VERSION"].toString()
val androidxActivityVersion = extra["ANDROIDX_ACTIVITY_VERSION"].toString()
val androidxAnnotationVersion = extra["ANDROIDX_ANNOTATION_VERSION"].toString()
val androidxAppcompatVersion = extra["ANDROIDX_APPCOMPAT_VERSION"].toString()
val androidxCameraVersion = extra["ANDROIDX_CAMERA_VERSION"].toString()
val androidxComposeCompilerVersion = extra["ANDROIDX_COMPOSE_COMPILER_VERSION"].toString()
2022-02-21 06:33:40 -08:00
val androidxComposeMaterial3Version = extra["ANDROIDX_COMPOSE_MATERIAL3_VERSION"].toString()
2021-12-03 05:19:15 -08:00
val androidxComposeVersion = extra["ANDROIDX_COMPOSE_VERSION"].toString()
val androidxConstraintlayoutVersion = extra["ANDROIDX_CONSTRAINTLAYOUT_VERSION"].toString()
val androidxCoreVersion = extra["ANDROIDX_CORE_VERSION"].toString()
val androidxEspressoVersion = extra["ANDROIDX_ESPRESSO_VERSION"].toString()
2021-10-09 07:36:58 -07:00
val androidxLifecycleVersion = extra["ANDROIDX_LIFECYCLE_VERSION"].toString()
val androidxNavigationComposeVersion = extra["ANDROIDX_NAVIGATION_COMPOSE_VERSION"].toString()
2021-12-03 05:19:15 -08:00
val androidxSecurityCryptoVersion = extra["ANDROIDX_SECURITY_CRYPTO_VERSION"].toString()
val androidxSplashScreenVersion = extra["ANDROIDX_SPLASH_SCREEN_VERSION"].toString()
val androidxTestCoreVersion = extra["ANDROIDX_TEST_CORE_VERSION"].toString()
val androidxTestJunitVersion = extra["ANDROIDX_TEST_JUNIT_VERSION"].toString()
2021-10-11 12:52:24 -07:00
val androidxTestOrchestratorVersion = extra["ANDROIDX_TEST_ORCHESTRATOR_VERSION"].toString()
val androidxTestRunnerVersion = extra["ANDROIDX_TEST_RUNNER_VERSION"].toString()
val androidxUiAutomatorVersion = extra["ANDROIDX_UI_AUTOMATOR_VERSION"].toString()
val androidxWorkManagerVersion = extra["ANDROIDX_WORK_MANAGER_VERSION"].toString()
val coreLibraryDesugaringVersion = extra["CORE_LIBRARY_DESUGARING_VERSION"].toString()
2022-04-04 06:37:00 -07:00
val flankVersion = extra["FLANK_VERSION"].toString()
val jacocoVersion = extra["JACOCO_VERSION"].toString()
val javaVersion = extra["ANDROID_JVM_TARGET"].toString()
val kotlinVersion = extra["KOTLIN_VERSION"].toString()
val kotlinxDateTimeVersion = extra["KOTLINX_DATETIME_VERSION"].toString()
val kotlinxCoroutinesVersion = extra["KOTLINX_COROUTINES_VERSION"].toString()
val playCoreVersion = extra["PLAY_CORE_VERSION"].toString()
val playCoreKtxVersion = extra["PLAY_CORE_KTX_VERSION"].toString()
val zcashBip39Version = extra["ZCASH_BIP39_VERSION"].toString()
2021-12-03 05:19:15 -08:00
val zcashSdkVersion = extra["ZCASH_SDK_VERSION"].toString()
2022-01-13 09:49:08 -08:00
val zxingVersion = extra["ZXING_VERSION"].toString()
// Standalone versions
2022-04-04 06:37:00 -07:00
version("flank", flankVersion)
version("jacoco", jacocoVersion)
version("java", javaVersion)
// Aliases
[#313] scan qr screen functional * [#312] [#309] Scaffold Scan QR Screen - Screen scaffolding. - Model classes. - Screen states handling. - Needed dependencies added. - Camera permission handling. Redirect to Settings. - Added SettingsUtilTest class. - Added view classes tests. - Renamed tag class in update package. - Fix the scan frame size while changing the screen orientation. - Use local variable for cameraProvider. - Use UUID for source of randomness. - Eliminate blocking call for camera. - Fix preview name. - Remove Google Guava dependency. - Suppress Lint warning. - Improved calculation of the camera frame size. Moved it into Constraint layout. - Added custom image analyser class. - Implemented logic for the QR scan screen while QR code is found. - Manual tests added. - New module with integration tests for QR Scan screen. Added 3 integration and 4 view tests. - Simplify QR Scan screen view basic tests. - Switched from pure compose permission handling to Accompanist way of handling CAMERA permission. - Added validation of Zcash wallet address from QR scanning result. - Fix the integration tests for the CI WTF emulator runs. - Add comment on RTL test result. - Improve waitForDeviceIdle() method. Use it on the other test too. - Change the integration test module main manifest package name. - Debounce scans. - Improve thread safety of scan collection. - Added instructions on how to set up an emulator in manual tests. - Replace compose collectAsState() with coroutine launch(). - Add sample() to get rid of several callback events at the same time. - Stop updating the scanState when it's already in Scanning state. - Fix condition on navigation. - Remove validateJob check. - Speed up the integration test - Wrap ImageAnalysis.qrCodeFlow to remember. - Auto-close the camera image when we're done with it in all cases. - Update minimal SDK version to 24 for WTF emulators. - Update Architecture documentation. - Removed extra blank space in ui-design module definition. - Add ui-integration-test-lib. - Update Mermaid diagram with newly added module. - Move UI modules into one wrap in the diagram. - Move sdk-ext-lib and sdk-ext-ui under the same modules section. - Update camera dependencies. Co-authored-by: Carter Jernigan <git@carterjernigan.com>
2022-06-02 04:35:51 -07:00
library("accompanist-permissions", "com.google.accompanist:accompanist-permissions:$accompanistPermissionsVersion")
2022-04-04 06:26:29 -07:00
library("androidx-activity", "androidx.activity:activity-ktx:$androidxActivityVersion")
library("androidx-activity-compose", "androidx.activity:activity-compose:$androidxActivityVersion")
library("androidx-annotation", "androidx.annotation:annotation:$androidxAnnotationVersion")
library("androidx-appcompat", "androidx.appcompat:appcompat:$androidxAppcompatVersion")
library("androidx-camera", "androidx.camera:camera-camera2:$androidxCameraVersion")
library("androidx-camera-lifecycle", "androidx.camera:camera-lifecycle:$androidxCameraVersion")
library("androidx-camera-view", "androidx.camera:camera-view:$androidxCameraVersion")
2022-04-04 06:26:29 -07:00
library("androidx-compose-foundation", "androidx.compose.foundation:foundation:$androidxComposeVersion")
library("androidx-compose-material3", "androidx.compose.material3:material3:$androidxComposeMaterial3Version")
library("androidx-compose-material-icons-core", "androidx.compose.material:material-icons-core:$androidxComposeVersion")
library("androidx-compose-material-icons-extended", "androidx.compose.material:material-icons-extended:$androidxComposeVersion")
library("androidx-compose-tooling", "androidx.compose.ui:ui-tooling:$androidxComposeVersion")
library("androidx-compose-ui", "androidx.compose.ui:ui:$androidxComposeVersion")
library("androidx-compose-compiler", "androidx.compose.compiler:compiler:$androidxComposeCompilerVersion")
library("androidx-core", "androidx.core:core-ktx:$androidxCoreVersion")
library("androidx-constraintlayout", "androidx.constraintlayout:constraintlayout-compose:$androidxConstraintlayoutVersion")
2022-04-04 06:26:29 -07:00
library("androidx-lifecycle-livedata", "androidx.lifecycle:lifecycle-livedata-ktx:$androidxLifecycleVersion")
library("androidx-navigation-compose", "androidx.navigation:navigation-compose:$androidxNavigationComposeVersion")
library("androidx-security-crypto", "androidx.security:security-crypto-ktx:$androidxSecurityCryptoVersion")
library("androidx-splash", "androidx.core:core-splashscreen:$androidxSplashScreenVersion")
library("androidx-viewmodel-compose", "androidx.lifecycle:lifecycle-viewmodel-compose:$androidxLifecycleVersion")
library("androidx-workmanager", "androidx.work:work-runtime-ktx:$androidxWorkManagerVersion")
library("desugaring", "com.android.tools:desugar_jdk_libs:$coreLibraryDesugaringVersion")
library("kotlin-stdlib", "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion")
library("kotlin-reflect", "org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion")
library("kotlin-test", "org.jetbrains.kotlin:kotlin-test:$kotlinVersion")
library("kotlinx-coroutines-android", "org.jetbrains.kotlinx:kotlinx-coroutines-android:$kotlinxCoroutinesVersion")
library("kotlinx-coroutines-core", "org.jetbrains.kotlinx:kotlinx-coroutines-core:$kotlinxCoroutinesVersion")
library("kotlinx-coroutines-guava", "org.jetbrains.kotlinx:kotlinx-coroutines-guava:$kotlinxCoroutinesVersion")
library("kotlinx-datetime", "org.jetbrains.kotlinx:kotlinx-datetime:$kotlinxDateTimeVersion")
library("play-core", "com.google.android.play:core:$playCoreVersion")
library("play-core-ktx", "com.google.android.play:core-ktx:$playCoreKtxVersion")
2022-04-04 06:26:29 -07:00
library("zcash-sdk", "cash.z.ecc.android:zcash-android-sdk:$zcashSdkVersion")
library("zcash-bip39", "cash.z.ecc.android:kotlin-bip39:$zcashBip39Version")
library("zcash-walletplgns", "cash.z.ecc.android:zcash-android-wallet-plugins:$zcashBip39Version")
library("zxing", "com.google.zxing:core:$zxingVersion")
// Test libraries
2022-04-04 06:26:29 -07:00
library("androidx-compose-test-junit", "androidx.compose.ui:ui-test-junit4:$androidxComposeVersion")
library("androidx-compose-test-manifest", "androidx.compose.ui:ui-test-manifest:$androidxComposeVersion")
// Cannot use espresso-contrib, because it causes a build failure
2022-04-04 06:26:29 -07:00
//alias("androidx-espresso-contrib", "androidx.test.espresso:espresso-contrib:$androidxEspressoVersion")
library("androidx-espresso-core", "androidx.test.espresso:espresso-core:$androidxEspressoVersion")
library("androidx-espresso-intents", "androidx.test.espresso:espresso-intents:$androidxEspressoVersion")
library("androidx-test-core", "androidx.test:core-ktx:$androidxTestCoreVersion")
library("androidx-test-junit", "androidx.test.ext:junit-ktx:$androidxTestJunitVersion")
2022-04-04 06:26:29 -07:00
library("androidx-test-orchestrator", "androidx.test:orchestrator:$androidxTestOrchestratorVersion")
library("androidx-test-runner", "androidx.test:runner:$androidxTestRunnerVersion")
library("androidx-uiAutomator", "androidx.test.uiautomator:uiautomator-v18:$androidxUiAutomatorVersion")
library("kotlinx-coroutines-test", "org.jetbrains.kotlinx:kotlinx-coroutines-test:$kotlinxCoroutinesVersion")
// Bundles
bundle(
"androidx-camera",
listOf(
"androidx-camera",
"androidx-camera-lifecycle",
"androidx-camera-view"
)
)
bundle(
"androidx-compose-core",
listOf(
"androidx-compose-compiler",
"androidx-compose-foundation",
2022-02-21 06:33:40 -08:00
"androidx-compose-material3",
"androidx-compose-tooling",
"androidx-compose-ui",
)
)
bundle(
"androidx-compose-extended",
listOf(
"androidx-activity-compose",
"androidx-compose-material-icons-core",
"androidx-compose-material-icons-extended",
"androidx-navigation-compose",
"androidx-viewmodel-compose"
)
)
bundle(
"play-core",
listOf(
"play-core",
"play-core-ktx",
)
)
bundle(
"androidx-test",
listOf(
"androidx-espresso-core",
"androidx-espresso-intents",
2021-10-11 12:52:24 -07:00
"androidx-test-core",
"androidx-test-junit",
"androidx-test-runner"
)
)
}
}
}
rootProject.name = "zcash-android-app"
includeBuild("build-convention")
include("app")
include("build-info-lib")
include("crash-lib")
include("crash-android-lib")
include("preference-api-lib")
include("preference-impl-android-lib")
include("sdk-ext-lib")
include("sdk-ext-ui-lib")
include("spackle-lib")
include("spackle-android-lib")
include("test-lib")
include("ui-design-lib")
[#313] scan qr screen functional * [#312] [#309] Scaffold Scan QR Screen - Screen scaffolding. - Model classes. - Screen states handling. - Needed dependencies added. - Camera permission handling. Redirect to Settings. - Added SettingsUtilTest class. - Added view classes tests. - Renamed tag class in update package. - Fix the scan frame size while changing the screen orientation. - Use local variable for cameraProvider. - Use UUID for source of randomness. - Eliminate blocking call for camera. - Fix preview name. - Remove Google Guava dependency. - Suppress Lint warning. - Improved calculation of the camera frame size. Moved it into Constraint layout. - Added custom image analyser class. - Implemented logic for the QR scan screen while QR code is found. - Manual tests added. - New module with integration tests for QR Scan screen. Added 3 integration and 4 view tests. - Simplify QR Scan screen view basic tests. - Switched from pure compose permission handling to Accompanist way of handling CAMERA permission. - Added validation of Zcash wallet address from QR scanning result. - Fix the integration tests for the CI WTF emulator runs. - Add comment on RTL test result. - Improve waitForDeviceIdle() method. Use it on the other test too. - Change the integration test module main manifest package name. - Debounce scans. - Improve thread safety of scan collection. - Added instructions on how to set up an emulator in manual tests. - Replace compose collectAsState() with coroutine launch(). - Add sample() to get rid of several callback events at the same time. - Stop updating the scanState when it's already in Scanning state. - Fix condition on navigation. - Remove validateJob check. - Speed up the integration test - Wrap ImageAnalysis.qrCodeFlow to remember. - Auto-close the camera image when we're done with it in all cases. - Update minimal SDK version to 24 for WTF emulators. - Update Architecture documentation. - Removed extra blank space in ui-design module definition. - Add ui-integration-test-lib. - Update Mermaid diagram with newly added module. - Move UI modules into one wrap in the diagram. - Move sdk-ext-lib and sdk-ext-ui under the same modules section. - Update camera dependencies. Co-authored-by: Carter Jernigan <git@carterjernigan.com>
2022-06-02 04:35:51 -07:00
include("ui-integration-test-lib")
include("ui-lib")
if (extra["IS_SDK_INCLUDED_BUILD"].toString().toBoolean()) {
// Currently assume the SDK is up one level with a hardcoded directory name
// If this becomes problematic, `IS_SDK_INCLUDED_BUILD` could be turned into a path
// instead.
includeBuild("../zcash-android-sdk") {
dependencySubstitution {
substitute(module("cash.z.ecc.android:zcash-android-sdk")).using(project(":sdk-lib"))
}
}
}