From ca221f268cb81b32a9c56869a4bca591edf74b0d Mon Sep 17 00:00:00 2001 From: Devasy Patel <110348311+Devasy23@users.noreply.github.com> Date: Wed, 17 Jun 2026 20:17:08 +0530 Subject: [PATCH] fix(fdroid): make release signing survive F-Droid key stripping F-Droid's build server deletes the `signingConfigs { ... }` block before building. The old `val releaseConfig = signingConfigs.getByName("release")` line survived that stripping and then referenced the removed config, failing with "SigningConfig with name 'release' not found". Collapse it to a single `signingConfig = ...` statement (which the stripper removes whole) using findByName + takeIf, so F-Droid falls back to its own signing. Local/CI release signing is unchanged. Also shorten the fastlane short_description to 71 chars; F-Droid pulls it as the Summary (80-char max) and the previous text was 83. Co-Authored-By: Claude Opus 4.8 --- workout-logger/android/app/build.gradle.kts | 15 ++++++++++----- .../metadata/android/en-US/short_description.txt | 2 +- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/workout-logger/android/app/build.gradle.kts b/workout-logger/android/app/build.gradle.kts index 727fd5e..6afbefa 100644 --- a/workout-logger/android/app/build.gradle.kts +++ b/workout-logger/android/app/build.gradle.kts @@ -61,11 +61,16 @@ android { } release { // Uses the production EC P-256 keystore when KEYSTORE_PATH env var is set - // (CI injects it via GitHub Secrets). Falls back to debug key for local - // flutter run --release without env vars configured. - val releaseConfig = signingConfigs.getByName("release") - signingConfig = if (releaseConfig.storeFile != null) releaseConfig - else signingConfigs.getByName("debug") + // (CI injects it via GitHub Secrets). Falls back to the debug key for a + // local `flutter run --release` without env vars configured. + // + // This MUST stay on a single line beginning with `signingConfig` so the + // F-Droid build server's signing-key stripper removes the whole statement + // (it deletes the `signingConfigs { ... }` block too, after which any + // surviving reference like `signingConfigs.getByName("release")` would + // fail with "SigningConfig with name 'release' not found"). F-Droid then + // signs the APK with its own key. + signingConfig = signingConfigs.findByName("release")?.takeIf { it.storeFile != null } ?: signingConfigs.getByName("debug") } } } diff --git a/workout-logger/fastlane/metadata/android/en-US/short_description.txt b/workout-logger/fastlane/metadata/android/en-US/short_description.txt index 81d203c..87804a8 100644 --- a/workout-logger/fastlane/metadata/android/en-US/short_description.txt +++ b/workout-logger/fastlane/metadata/android/en-US/short_description.txt @@ -1 +1 @@ -Workout logger with AI coaching, progress analytics, and Health Connect integration \ No newline at end of file +Workout logger with AI coaching, analytics & Health Connect integration