Three APKs: the notification listener leaves the standard builds; releases drop x86_64
CI / check (push) Canceled after 0s

Google Play Protect blocked installing beta.7, most likely for the
notification listener (notification summaries).

- A second flavour dimension, `reading`: `standard` declares no listener and
  no permission of it; `notifications` is the full build plus the listener,
  with the same application id and key. Variants: fullStandard,
  fullNotifications, fdroidStandard (no F-Droid build with the listener).
  The listener class and its manifest entry live in src/notifications only.
- Settings in a standard build says where notification summaries went and
  why. The self-updater installs only its own kind: a notifications build
  takes latest.json's optional `notifications {url, sha256}` or nothing.
- Release builds carry arm64-v8a and armeabi-v7a only; debug keeps x86_64
  for the emulator. The engine's unused C and C++ API libraries are left out.
- scripts/check-apk.sh checks the built files (listener only where it may
  be, model stored, no x86 in a release); CI runs it on the three debug APKs
  and on an unsigned release build, release.yml on what it publishes.
- release.yml publishes llembas-android-<version>.apk, -notifications.apk
  and -fdroid.apk with SHA256SUMS.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
HomerandClaude Fable 5.2 committed 2026-11-12 09:58:07 +00:00
1 parent 6a05f56e7c
commit f2a2acf996
28 files changed
+403 -140

No files matched your search

+26 -7
View File
@@ -53,22 +53,41 @@ jobs:
- uses: gradle/actions/setup-gradle@v4
- name: Unit tests and both builds
run: ./gradlew --no-daemon testFullDebugUnitTest assembleFullDebug assembleFdroidDebug
- name: Unit tests and the three builds
run: >
./gradlew --no-daemon testFullStandardDebugUnitTest
assembleFullStandardDebug assembleFullNotificationsDebug assembleFdroidStandardDebug
# The files themselves: only the notifications build declares a notification listener, the
# wake-word model is stored uncompressed, the F-Droid build has no engine.
- name: What the APKs declare
run: |
scripts/check-apk.sh app/build/outputs/apk/fullStandard/debug/app-full-standard-debug.apk standard
scripts/check-apk.sh app/build/outputs/apk/fullNotifications/debug/app-full-notifications-debug.apk notifications
scripts/check-apk.sh app/build/outputs/apk/fdroidStandard/debug/app-fdroid-standard-debug.apk fdroid
# A release as the release workflow builds it, unsigned: shrunk by R8, and without the
# emulator's x86_64 libraries. Found here rather than at a tag.
- name: The release build's shape
run: |
./gradlew --no-daemon assembleFullStandardRelease
scripts/check-apk.sh "$(ls app/build/outputs/apk/fullStandard/release/*.apk)" standard release
- name: Android lint (report only, for now)
run: ./gradlew --no-daemon lintFullDebug
run: ./gradlew --no-daemon lintFullStandardDebug
continue-on-error: true
# The test build a tester installs (Actions › this run › Artifacts): debug-signed with the
# repository's public test key, so each one installs over the last. `full` is the one to
# use; `fdroid` is the same app without the updater.
# repository's public test key, so each one installs over the last. The plain one is the
# one to use; `-notifications` is the same app with the notification listener (it installs
# over the plain one and back); `-fdroid` is the app without the updater and the wake word.
- name: Name the test builds
run: |
mkdir test-builds
short="${GITHUB_SHA::7}"
cp app/build/outputs/apk/full/debug/app-full-debug.apk "test-builds/llembas-android-debug-$GITHUB_RUN_NUMBER-$short.apk"
cp app/build/outputs/apk/fdroid/debug/app-fdroid-debug.apk "test-builds/llembas-android-debug-$GITHUB_RUN_NUMBER-$short-fdroid.apk"
cp app/build/outputs/apk/fullStandard/debug/app-full-standard-debug.apk "test-builds/llembas-android-debug-$GITHUB_RUN_NUMBER-$short.apk"
cp app/build/outputs/apk/fullNotifications/debug/app-full-notifications-debug.apk "test-builds/llembas-android-debug-$GITHUB_RUN_NUMBER-$short-notifications.apk"
cp app/build/outputs/apk/fdroidStandard/debug/app-fdroid-standard-debug.apk "test-builds/llembas-android-debug-$GITHUB_RUN_NUMBER-$short-fdroid.apk"
(cd test-builds && sha256sum *.apk > SHA256SUMS)
- uses: actions/upload-artifact@v4
+12 -5
View File
@@ -1,7 +1,8 @@
name: Release
# A signed tag `vX.Y.Z` builds both flavours, signed with the release key from the secrets,
# and publishes them with SHA256SUMS as the GitHub Release. The release notes are the tag's
# A signed tag `vX.Y.Z` builds the three APKs, signed with the release key from the secrets,
# and publishes them with SHA256SUMS as the GitHub Release: the standard one, `-notifications`
# (the same app, id and key, plus the notification listener) and `-fdroid`. The release notes are the tag's
# message. The key never touches the repository: it is written to a temporary file here and
# deleted with the runner.
on:
@@ -61,14 +62,20 @@ jobs:
[ -n "$KEYSTORE_B64" ] || { echo "no release key in the secrets" >&2; exit 1; }
export LEMBAS_KEYSTORE="$RUNNER_TEMP/release.jks"
echo "$KEYSTORE_B64" | base64 -d > "$LEMBAS_KEYSTORE"
./gradlew --no-daemon testFullReleaseUnitTest assembleFullRelease assembleFdroidRelease
./gradlew --no-daemon testFullStandardReleaseUnitTest assembleFullStandardRelease assembleFullNotificationsRelease assembleFdroidStandardRelease
rm -f "$LEMBAS_KEYSTORE"
- name: Name the files and sum them
run: |
mkdir dist
cp app/build/outputs/apk/full/release/app-full-release.apk "dist/llembas-android-$VERSION.apk"
cp app/build/outputs/apk/fdroid/release/app-fdroid-release.apk "dist/llembas-android-$VERSION-fdroid.apk"
cp app/build/outputs/apk/fullStandard/release/app-full-standard-release.apk "dist/llembas-android-$VERSION.apk"
cp app/build/outputs/apk/fullNotifications/release/app-full-notifications-release.apk "dist/llembas-android-$VERSION-notifications.apk"
cp app/build/outputs/apk/fdroidStandard/release/app-fdroid-standard-release.apk "dist/llembas-android-$VERSION-fdroid.apk"
# What is about to be published, checked on the files: the listener only in
# -notifications, the model stored, no x86_64 library.
scripts/check-apk.sh "dist/llembas-android-$VERSION.apk" standard release
scripts/check-apk.sh "dist/llembas-android-$VERSION-notifications.apk" notifications release
scripts/check-apk.sh "dist/llembas-android-$VERSION-fdroid.apk" fdroid release
{ echo "# llembas-android $VERSION"; (cd dist && sha256sum *.apk); } > SHA256SUMS
mv SHA256SUMS dist/