Skip to content

feat: Implement automated release workflow for Android APKs, includin… - #15

Merged
Devasy merged 3 commits into
mainfrom
release-workflow
Jan 26, 2026
Merged

feat: Implement automated release workflow for Android APKs, includin…#15
Devasy merged 3 commits into
mainfrom
release-workflow

Conversation

@Devasy

@DevasyDevasy commented Jan 26, 2026

Copy link
Copy Markdown
Owner

…g version bumping and GitHub Releases.

Summary by CodeRabbit

Release Notes

  • New Features

    • Android APKs are automatically built, versioned, and published to GitHub Releases when changes are merged to main.
    • Patch and build numbers are incremented automatically during release.
  • Documentation

    • Added comprehensive release workflow docs with setup, versioning strategy, signing guidance, and troubleshooting.

✏️ Tip: You can customize this high-level summary in your review settings.

@Devasy

Copy link
Copy Markdown
OwnerAuthor

@coderabbitai review

@coderabbitai

Copy link
Copy Markdown
Contributor
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai

coderabbitaiBot commented Jan 26, 2026

Copy link
Copy Markdown
Contributor

Warning

Rate limit exceeded

@Devasy has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 8 minutes and 27 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

Walkthrough

Adds an automated release pipeline: a GitHub Actions workflow to bump versions, build and publish a Flutter Android APK from main; a Dart script that increments pubspec.yaml patch/build numbers; and documentation describing the workflow, versioning, setup, and release steps.

Changes

Cohort / File(s)Summary
Release Automation
.github/workflows/release.yml, scripts/bump_version.dart
Adds a GitHub Actions workflow that triggers on push to main, sets up Java (Temurin 17) and Flutter (3.27.2), installs deps for workout-logger, runs scripts/bump_version.dart to bump patch/build, commits and tags changes, builds and renames the release APK, and creates a GitHub Release attaching the APK. The Dart script validates and parses workout-logger/pubspec.yaml, increments patch (when requested) and build number, writes the new version: line, prints NEW_VERSION=<newVersion>, and appends CI output when GITHUB_OUTPUT is set; exits nonzero on errors.
Release Documentation
docs/RELEASE_WORKFLOW.md
Adds detailed documentation covering the automated release workflow, trigger and versioning strategy (automatic patch increments, manual minor/major), initial release steps, APK installation and signing guidance, workflow permissions/branch-protection notes, troubleshooting, and a workflow diagram.
🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check nameStatusExplanation
Description Check✅ PassedCheck skipped - CodeRabbit’s high-level summary is enabled.
Title check✅ PassedThe title clearly summarizes the main change: implementing an automated release workflow for Android APKs with version bumping and GitHub Releases, which aligns with all three files added (release workflow, documentation, and version bump script).
Docstring Coverage✅ PassedNo functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitaicoderabbitaiBot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 6

🤖 Fix all issues with AI agents
In @.github/workflows/release.yml:
- Around line 72-73: Replace the pinned GitHub Action version for the release
step: locate the uses entry "softprops/action-gh-release@v1" and update it to
"softprops/action-gh-release@v2" so the workflow runs the maintained v2 release
action; after updating, run or validate the workflow to ensure any v2-specific
inputs or outputs (if present) are still compatible with the surrounding steps
(the "Create GitHub Release" job/step).
- Around line 51-61: The workflow currently always runs the "Create Git tag"
step even when the "Commit version bump" step made no commit (id:
commit_version), which can fail or duplicate tags; modify the commit step to
detect whether git commit succeeded and emit a step output (e.g., write
committed=true/false to GITHUB_OUTPUT from the step that runs git commit using
the bump_version.outputs.version), and then make the "Create Git tag" step
conditional (use if: steps.commit_version.outputs.committed == 'true') so tags
are only created/pushed when a new commit was actually made; optionally also
check for existing tag before creating to avoid duplicate-tag errors.
- Around line 3-6: The workflow currently triggers on every push to the main
branch (the "on: push: branches: - main" block) which includes the automated
version-bump commit and can loop; modify the workflow trigger or job-level
conditions to skip runs created by the GitHub Actions bot by either adding a
job-level conditional like "if: github.actor != 'github-actions[bot]'" (or your
bot actor), or add logic in the push step that includes "[skip ci]" in the
automated commit message and skip commits containing that tag, or use
"paths-ignore" or an equivalent check to exclude the automated commit—apply this
change to the release workflow so automated version-bump pushes do not
re-trigger the release.
In `@docs/RELEASE_WORKFLOW.md`:
- Around line 19-23: The "Version Format" heading and its fenced code block lack
surrounding blank lines and a language identifier; update the Markdown so every
heading (e.g., "Version Format", "🔧 Setup Instructions") has a blank line above
and below, ensure fenced code blocks (the YAML example under "Version Format"
and the workflow diagram text block) are separated by blank lines and include
appropriate language identifiers (e.g., ```yaml for the version snippet, ```text
for the diagram). Apply the same pattern to the other flagged sections (around
the headings and fenced blocks in the ranges mentioned) to ensure consistent
spacing and parser compatibility.
In `@scripts/bump_version.dart`:
- Around line 37-41: The current logic increments both patch and build together
(variables patch and build, producing newPatch, newBuild and newVersion), which
couples patch bumps to every CI merge; change it so build increments
independently by default (newBuild = build + 1) while patch only increments when
an explicit patch bump is requested (e.g., check a bump type/flag and set
newPatch = patch + 1 only if bumpPatch/bumpType == 'patch'; otherwise newPatch =
patch), then construct newVersion = '$major.$minor.$newPatch+$newBuild'
accordingly; update any callers to pass the bump flag if needed.
- Around line 23-25: The current RegExp used to parse the version
(r'version:\s*(\d+)\.(\d+)\.(\d+)\+(\d+)') requires a +N build suffix and will
fail for "version: 1.0.0"; change the pattern to make the +build part optional
(e.g. use a non-capturing optional group for the "+digits") and then when
extracting the build from versionMatch (the code that reads
versionMatch.group(4)) handle the possible null by defaulting to 0 (or another
sensible default) before parsing; ensure you update any code that assumes the
build group always exists so it checks for null and parses accordingly.

Comment thread.github/workflows/release.yml
Comment thread.github/workflows/release.yml
Comment thread.github/workflows/release.yml Outdated
Comment threaddocs/RELEASE_WORKFLOW.md
Comment threadscripts/bump_version.dart
Comment threadscripts/bump_version.dart Outdated
@Devasy

Copy link
Copy Markdown
OwnerAuthor

@coderabbitai review

@coderabbitai

Copy link
Copy Markdown
Contributor
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitaicoderabbitaiBot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In @.github/workflows/release.yml:
- Around line 41-45: The "Bump version" step (id: bump_version) currently runs
"dart scripts/bump_version.dart" with no arguments so a patch bump is not
triggered; update the step to pass the "patch" argument to the script (i.e., run
the bump_version.dart with "patch") so the intended "patch on every merge"
behavior occurs, or alternatively update the workflow docs if you want
build-only bumps instead.
In `@docs/RELEASE_WORKFLOW.md`:
- Around line 19-30: Remove trailing whitespace on blank lines in the "Version
Format" section and surrounding markdown (the blank lines before/after the YAML
code block and between the "Version Format" header and "🔧 Setup Instructions")
to satisfy markdownlint MD009; update the RELEASE_WORKFLOW.md content by
trimming any trailing spaces on those blank lines (or run a
whitespace-trim/markdownlint autofix) so no blank line ends with spaces.

Comment thread.github/workflows/release.yml
Comment threaddocs/RELEASE_WORKFLOW.md
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
@Devasy
Devasy merged commit 3f5828e into mainJan 26, 2026
1 check passed
@Devasy
Devasy deleted the release-workflow branch January 26, 2026 19:31
Sign up for freeto 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.

1 participant

@Devasy