Conversation
Today release notes are a single static file at app/src/main/play/release-notes/en-US/internal.txt, so every release goes out with whatever was last committed there. Customizing per-release required editing + committing + tagging in three steps. Now the workflow extracts the annotated tag's message via `git for-each-ref --format='%(contents)' refs/tags/<tag>` and writes it to the per-track release-notes file before publishReleaseBundle runs. The release flow becomes one CLI invocation: git tag -a android/v1.7.0-production -m "What users see in Play Store" git push origin android/v1.7.0-production Lightweight tags (no -m / no -a) skip the step and fall back to whatever file is in the repo today, so existing tag commands still work. Implementation notes: - actions/checkout gets `fetch-tags: true` so the tag object's annotation is reachable; without it, only the tag's commit is fetched. - The notes file is written under the resolved track (production / beta / alpha / internal), so a single workflow handles all four. - Google Play caps notes at 500 chars per locale per release. We don't truncate — we emit `::warning::` and let publishReleaseBundle reject, so the tagger gets a loud signal to shorten and re-tag rather than silently shipping a half-sentence. - Only English (en-US) for now — matches the single locale already in the release-notes/ directory. Multi-locale support can be added later by parsing a structured tag-message format. Side note: there's a duplicate android-release.yml at android/.github/ that GitHub doesn't read (only repo-root .github/ is honored). Deletion is a separate cleanup, not part of this change. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Currently every Android release ships with whatever's in the static
app/src/main/play/release-notes/en-US/internal.txtfile. Customizing per release means editing, committing, then tagging — three steps for what should be one.This change makes the release flow one CLI command:
CI extracts the tag's annotation message and writes it to the per-track release-notes file before
publishReleaseBundleruns.How it works
android/app/src/main/play/release-notes/en-US/${TRACK}.txt.actions/checkout@v4getsfetch-tags: trueso the tag object's annotation is reachable (default checkout only fetches the tag's commit, not the tag object itself).git tag <name>with no-mor-a) are skipped — the workflow logs a fallback message and uses whatever file is already in the repo. Existing tag commands keep working.Why no truncation
Google Play caps notes at 500 chars per locale per release. We emit
::warning::if the message exceeds that, but letpublishReleaseBundlereject loudly — better the tagger sees the failure and re-tags with a shorter message than silently ship a half-sentence.Test plan
This is a CI workflow change; the only realistic test is to push an annotated tag against an internal track and watch the run.
git tag -a android/v1.7.x -m "Test note from tag"+ push → workflow logs show "Wrote N bytes to .../internal.txt" + preview block + AAB publishes with the new notes visible in Play Console.git tag android/v1.7.y(no-m) + push → workflow logs show "Tag 'android/v1.7.y' has no annotation; falling back…" + AAB publishes with the existing staticinternal.txtcontent.-m→ workflow shows the::warning::,publishReleaseBundlerejects, run fails clearly.Side note (not addressed here)
There's a duplicate
android-release.ymlatandroid/.github/workflows/that GitHub does not read (only repo-root.github/is honored). Both files are tracked but only the root one runs. Cleanup deletion is a separate concern.🤖 Generated with Claude Code