Skip to content

[MOB] Prepare the Android app for F-Droid - #157

Merged
mrsumanbiswas merged 2 commits into
CommandLineCoding:v0.3.0from
mrsumanbiswas:156-f-droid
Oct 9, 2026
Merged

mrsumanbiswas merged 2 commits into
CommandLineCoding:v0.3.0from
mrsumanbiswas:156-f-droid

Conversation

@mrsumanbiswas

Copy link
Copy Markdown
Member

Closes #156

Summary

Makes the Android app buildable and publishable on F-Droid, and fixes release versioning and signing along the way.

  • Versioning: pubspec.yaml was still 0.2.0+2 while v0.2.0–v0.3.0 shipped, so every release had versionCode 2. Bumped to 0.3.1+3. The release workflow now fails if the tag doesn't match pubspec.yaml.
  • Per-ABI versionCodes: the custom ×10 + abi block stacked on Flutter's own scheme, producing 1031/2031/4031. It now uses Flutter's scheme only: 1003 / 2003 / 4003.
  • Signing: release builds no longer use the debug key. They sign from android/key.properties or CI secrets (ANDROID_KEYSTORE_BASE64, ANDROID_KEYSTORE_PASSWORD, ANDROID_KEY_ALIAS, ANDROID_KEY_PASSWORD), and are unsigned otherwise, as F-Droid expects.
  • F-Droid compliance: disabled AGP's encrypted dependency-info block and removed the "FOSS sanitizer" task, which turned out to be unnecessary.
  • Flutter pinned to 3.47.2 in the release workflow; F-Droid's recipe reads it from there.
  • Store listing (metadata/en-US/): files renamed to what F-Droid reads (full_description.txt, changelogs/), texts rewritten.
  • fdroid/: the recipe to submit to fdroiddata, plus a release guide.

Type of Change

  • Bug fix
  • New feature
  • Refactoring
  • Documentation update

Testing Performed

  • Verified on emulator/physical device.

  • Code passes lint checks.

  • fdroid lint passes on the recipe; fdroid rewritemeta makes no changes

  • fdroid scanner: source tree clean; all three release APKs clean (non-free classes, extra signing blocks)

  • Release dependency graph: no Google Play, GMS or Firebase

  • flutter build apk --release --split-per-abi --target-platform=android-arm64 → app-arm64-v8a-release.apk, versionCode 2003, unsigned

  • Signing via env vars tested with a throwaway keystore

Notes

  • After merging, tag v0.3.1 so F-Droid can build it.
  • Add the four signing secrets so GitHub release APKs share one key. Without them CI falls back to a throwaway debug key, with a warning.

- Sign release builds from key.properties or ELEPHANT_* env vars
  (CI secrets); otherwise leave them unsigned for F-Droid. The debug
  key is only used when CI explicitly allows it.
- Disable AGP's dependency-info block, which F-Droid rejects
- Drop the "FOSS sanitizer" task: R8 already removes Flutter's Play
  Store classes, and fdroid scanner finds no non-free code in the APKs
- Use Flutter's per-ABI versionCodes (1000/2000/4000 + build number)
  instead of stacking a second scheme on top of it
- Bump version to 0.3.1+3 (it was stuck at 0.2.0+2 since v0.2.0)
- Move launcher_name and flutter_launcher_icons to dev_dependencies
- CI: pin Flutter 3.47.2, enforce pubspec.lock, fail when the tag
  doesn't match pubspec.yaml, sign with ANDROID_KEYSTORE_* secrets
- Store listing: rename to full_description.txt and changelogs/
  (the names F-Droid reads), rewrite the texts, add 4003.txt changelog
- Add the fdroiddata build recipe and a release guide under fdroid/

Refs CommandLineCoding#156
@mrsumanbiswas
mrsumanbiswas merged commit d65d6c1 into CommandLineCoding:v0.3.0 Oct 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

f-droid

1 participant