From d563a12f113d997f5691bff278d48a78dea4ca14 Mon Sep 17 00:00:00 2001 From: jahruz67 Date: Thu, 21 May 2026 23:03:25 -0700 Subject: [PATCH] Refactor Android build process to support update-compatible APKs and add shared debug keystore configuration --- .github/workflows/android-build.yml | 8 +------- app/build.gradle | 18 ++++++++++++++++++ app/signing/README.md | 3 +++ app/signing/bible-daily-debug.keystore | Bin 0 -> 2618 bytes build/reports/problems/problems-report.html | 2 +- 5 files changed, 23 insertions(+), 8 deletions(-) create mode 100644 app/signing/README.md create mode 100644 app/signing/bible-daily-debug.keystore diff --git a/.github/workflows/android-build.yml b/.github/workflows/android-build.yml index da5d00d..2a12a48 100644 --- a/.github/workflows/android-build.yml +++ b/.github/workflows/android-build.yml @@ -26,16 +26,10 @@ jobs: - name: Set up Gradle uses: gradle/actions/setup-gradle@v4 - - name: Cache Android debug keystore - uses: actions/cache@v4 - with: - path: ~/.android/debug.keystore - key: android-debug-keystore-${{ runner.os }} - - name: Make Gradle wrapper executable run: chmod +x gradlew - - name: Build debug APK + - name: Build update-compatible APK run: ./gradlew assembleDebug -PciVersionCode=${{ github.run_number }} -PciVersionName=1.0.${{ github.run_number }} - name: Prepare release assets diff --git a/app/build.gradle b/app/build.gradle index 72d0204..4341226 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -4,11 +4,21 @@ plugins { def ciVersionCode = providers.gradleProperty("ciVersionCode").getOrNull() def ciVersionName = providers.gradleProperty("ciVersionName").getOrNull() +def sharedDebugKeystore = file("signing/bible-daily-debug.keystore") android { namespace "com.bibliadiaria.app" compileSdk 35 + signingConfigs { + sharedDebug { + storeFile sharedDebugKeystore + storePassword "android" + keyAlias "androiddebugkey" + keyPassword "android" + } + } + defaultConfig { applicationId "com.bibliadiaria.app" minSdk 23 @@ -17,6 +27,14 @@ android { versionName ciVersionName != null ? ciVersionName : "1.0" } + buildTypes { + debug { + if (sharedDebugKeystore.exists()) { + signingConfig signingConfigs.sharedDebug + } + } + } + compileOptions { sourceCompatibility JavaVersion.VERSION_17 targetCompatibility JavaVersion.VERSION_17 diff --git a/app/signing/README.md b/app/signing/README.md new file mode 100644 index 0000000..1dc0325 --- /dev/null +++ b/app/signing/README.md @@ -0,0 +1,3 @@ +This debug keystore is intentionally shared by local and GitHub Actions builds so sideloaded APK updates keep the same Android signing identity. + +Do not use this key for Play Store or production release signing. diff --git a/app/signing/bible-daily-debug.keystore b/app/signing/bible-daily-debug.keystore new file mode 100644 index 0000000000000000000000000000000000000000..dd872c689b50c98b0a39b5f647b754f2ac223103 GIT binary patch literal 2618 zcma)8XEfZ6^4_K|5hX&{=+PoSHP{d}N>*7bIu@e z;Rcp(Zo)GUdasXZcFL#vaC+%gY8r4CB@Qck;QXcy^xqj~GW?cha0+A}LRS>FhNjwL zaEt;@Mx=1{Joo7zGN{6PY|_iRZ9#XXl6=S?!Co=-1e&AX=!6^*($6p()H9CDVcGGT zf~*VRXK452C!&-^xzN*O0T%g@IP<$nd}O z+COnra!F21vLx9WM)oti`z9NGwS9T75-TgAysMEQEjc#xiTRLoA4rbD7Dov(EY1%AMovjK3~1#d{zu@@<&`=>c=_bGB`dS&zdHSBEjuLcg=}|P4EW% z@n^)fBdYn=btk;f8&zV~%yK-K=+My~(`E0yVbf0g5D7T7U`Xmv_f(B)++}Y6f-}z6 zzs8v>dmd`j6Ir;0x`TxRJjlN$mSZ5Vy}ze^W$iwzNaNa@oW`UYZ3RnD&Y)SX1T8+N zL6a)28daM&4Sk0xt~?ld7|wnARvz%?xq>n>3z}7xdL(rQPHKICq+eD%`=M3-J3l;b z2Vb4JX+JpYKt9zFnC@7qc{@7LK2s;7Vuk&&xKsGRfTr&7SZuq+3UBQE`U4!a$mau- zytX;Ely|f@STtfl0L|xHf8JMEpp_miCYcV z&?$aat8wEP#)~T(UjY%5%s4BCH+r>$)$d$l&LPSLmxfutjS@-Pd0v&kP%?(tw_&bx zCxw-2$`6_TTo8n^@0)|*&m$G4-z&Q4JMUff8mr9`%`lHERyjU|J9c!?E4gV2TRf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KEDS<8 zaAQG42hm8mc#0$O<)h}NxmBzb function configurationCacheProblems() { return ( // begin-report-data -{"diagnostics":[{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('namespace = ') instead."}]]},{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('compileSdk = ') instead."}]]},{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('minSdk = ') instead."}]]},{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('targetSdk = ') instead."}]]},{"locations":[{"path":"C:\\Users\\360he\\Documents\\Bible app\\app\\src\\main\\java\\com\\bibliadiaria\\app\\ExtrasActivity.java"},{"taskPath":":app:compileDebugJavaWithJavac"}],"problem":[{"text":"Some input files use or override a deprecated API."}],"severity":"ADVICE","problemDetails":[{"text":"Note: Some input files use or override a deprecated API."}],"contextualLabel":"Some input files use or override a deprecated API.","problemId":[{"name":"java","displayName":"Java compilation"},{"name":"compilation","displayName":"Compilation"},{"name":"compiler.note.deprecated.plural","displayName":"Some input files use or override a deprecated API."}]},{"locations":[{"path":"C:\\Users\\360he\\Documents\\Bible app\\app\\src\\main\\java\\com\\bibliadiaria\\app\\ExtrasActivity.java"},{"taskPath":":app:compileDebugJavaWithJavac"}],"problem":[{"text":"Recompile with -Xlint:deprecation for details."}],"severity":"ADVICE","problemDetails":[{"text":"Note: Recompile with -Xlint:deprecation for details."}],"contextualLabel":"Recompile with -Xlint:deprecation for details.","problemId":[{"name":"java","displayName":"Java compilation"},{"name":"compilation","displayName":"Compilation"},{"name":"compiler.note.deprecated.recompile","displayName":"Recompile with -Xlint:deprecation for details."}]}],"problemsReport":{"totalProblemCount":6,"buildName":"Biblia Diaria","requestedTasks":"assembleDebug","documentationLink":"https://docs.gradle.org/9.0.0/userguide/reporting_problems.html","documentationLinkCaption":"Problem report","summaries":[]}} +{"diagnostics":[{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('namespace = ') instead."}]]},{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('compileSdk = ') instead."}]]},{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('minSdk = ') instead."}]]},{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('targetSdk = ') instead."}]]},{"problem":[{"text":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"severity":"WARNING","problemDetails":[{"text":"This is scheduled to be removed in Gradle 10."}],"contextualLabel":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated.","documentationLink":"https://docs.gradle.org/9.0.0/userguide/upgrading_version_8.html#groovy_space_assignment_syntax","problemId":[{"name":"deprecation","displayName":"Deprecation"},{"name":"properties-should-be-assigned-using-the-propname-value-syntax-setting-a-property-via-the-gradle-generated-propname-value-or-propname-value-syntax-in-groovy-dsl","displayName":"Properties should be assigned using the 'propName = value' syntax. Setting a property via the Gradle-generated 'propName value' or 'propName(value)' syntax in Groovy DSL has been deprecated."}],"solutions":[[{"text":"Use assignment ('signingConfig = ') instead."}]]}],"problemsReport":{"totalProblemCount":5,"buildName":"Biblia Diaria","requestedTasks":"assembleDebug","documentationLink":"https://docs.gradle.org/9.0.0/userguide/reporting_problems.html","documentationLinkCaption":"Problem report","summaries":[]}} // end-report-data );}