SHA256
Add real native onboarding/auth/dashboard/tasks/notes/shopping, origin-bound HTTPS and encrypted AndroidKeyStore session persistence. Archive the superseded browser renderer and tests. Verify 10 JVM tests, 6 native API-35 emulator tests, lintDebug/lintRelease and debug/unsigned release APK/AAB builds; the real upstream suite passes 7 tests and exports a nonblank native fixture screenshot. Tink host-tool update removes the old generated-protobuf warning. Full module/visual parity remains explicitly incomplete.
108 lines
4.1 KiB
Kotlin
108 lines
4.1 KiB
Kotlin
plugins {
|
|
id("com.android.application")
|
|
id("org.jetbrains.kotlin.plugin.compose")
|
|
}
|
|
|
|
android {
|
|
namespace = "community.yuvomi.mobile"
|
|
compileSdk { version = release(37) { minorApiLevel = 0 } }
|
|
defaultConfig {
|
|
applicationId = "community.yuvomi.mobile"
|
|
minSdk = 26
|
|
targetSdk = 37
|
|
versionCode = 2
|
|
versionName = "0.2.0-native-preview"
|
|
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
|
}
|
|
buildTypes {
|
|
release {
|
|
isMinifyEnabled = true
|
|
isShrinkResources = true
|
|
proguardFiles(
|
|
getDefaultProguardFile("proguard-android-optimize.txt"),
|
|
"proguard-rules.pro",
|
|
)
|
|
// Signing is deliberately supplied by the authorized release maintainer.
|
|
}
|
|
create("integration") {
|
|
initWith(getByName("debug"))
|
|
applicationIdSuffix = ".integration"
|
|
matchingFallbacks += "debug"
|
|
}
|
|
}
|
|
compileOptions {
|
|
sourceCompatibility = JavaVersion.VERSION_17
|
|
targetCompatibility = JavaVersion.VERSION_17
|
|
}
|
|
buildFeatures { compose = true }
|
|
sourceSets.getByName("androidTest").kotlin.directories.apply {
|
|
clear()
|
|
add("src/androidTestNative/java")
|
|
}
|
|
lint {
|
|
abortOnError = true
|
|
warningsAsErrors = true
|
|
}
|
|
if (providers.gradleProperty("integration").isPresent) {
|
|
testBuildType = "integration"
|
|
sourceSets.getByName(
|
|
"androidTest",
|
|
).kotlin.directories.add("src/androidTestNativeIntegration/java")
|
|
val testResources = providers.environmentVariable("YUVOMI_TEST_RES").get()
|
|
sourceSets.getByName("integration").res.directories.add(testResources)
|
|
defaultConfig.testInstrumentationRunnerArguments["server"] =
|
|
providers.environmentVariable("YUVOMI_TEST_URL").get()
|
|
defaultConfig.testInstrumentationRunnerArguments["password"] =
|
|
providers.environmentVariable("YUVOMI_TEST_PASSWORD").get()
|
|
}
|
|
}
|
|
|
|
kotlin { compilerOptions { jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_17) } }
|
|
|
|
dependencyLocking { lockAllConfigurations() }
|
|
|
|
// AGP's device-test tools still request vulnerable older wire libraries. These
|
|
// are host-only, not APK dependencies; stay within binary-compatible minor lines.
|
|
configurations.configureEach {
|
|
if (name.startsWith("_internal-unified-test-platform") || name == "androidLintTool" ||
|
|
name == "unified-test-platform-gradle-work-action"
|
|
) {
|
|
resolutionStrategy.eachDependency {
|
|
when (requested.group) {
|
|
"io.netty" -> {
|
|
useVersion("4.1.139.Final")
|
|
because("Remediate published host-test HTTP/TLS advisories")
|
|
}
|
|
"com.google.protobuf" -> {
|
|
useVersion("3.25.9")
|
|
because("Remediate protobuf recursion/DoS advisories")
|
|
}
|
|
"org.bouncycastle" -> {
|
|
useVersion("1.86")
|
|
because("Remediate published build-tool cryptography advisories")
|
|
}
|
|
"org.apache.commons" -> if (requested.name == "commons-lang3") useVersion("3.21.0")
|
|
"org.apache.httpcomponents" -> if (requested.name ==
|
|
"httpclient"
|
|
) {
|
|
useVersion("4.5.14")
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
implementation("androidx.activity:activity-ktx:1.10.1")
|
|
implementation("androidx.core:core-ktx:1.16.0")
|
|
implementation("androidx.activity:activity-compose:1.10.1")
|
|
implementation("androidx.compose.material3:material3:1.4.0")
|
|
implementation("androidx.lifecycle:lifecycle-viewmodel-compose:2.9.4")
|
|
testImplementation("junit:junit:4.13.2")
|
|
testImplementation("org.json:json:20260814")
|
|
androidTestImplementation("androidx.test:runner:1.6.2")
|
|
androidTestImplementation("androidx.test.ext:junit:1.2.1")
|
|
androidTestImplementation("androidx.test.espresso:espresso-core:3.6.1")
|
|
androidTestImplementation("androidx.compose.ui:ui-test-junit4:1.9.0")
|
|
}
|