ci: install bun in release job so AI changelog generates
What
- Add
oven-sh/setup-bun@v2to the tag publish job in.github/workflows/build.yml, so the existingGenerate AI changelogstep can actually run.
Why
Every release from 8.3.5 to 8.3.12 shipped with the placeholder body:
_Changelog was not generated automatically for this release._
and a self-referential compare link (compare/8.3.12...8.3.12), because steps.changelog.outputs.result, from_tag, and to_tag were all empty.
The wiring other Cap-go plugin repos use (id: changelog, continue-on-error: true, Cloudflare secrets, fetch-depth: 0, and the action-gh-release body referencing steps.changelog.outputs.*) was already present here. The step itself failed. From the 8.3.12 run (31664632096):
Run bun run changelog:ai
CLOUDFLARE_API_TOKEN: ***
CLOUDFLARE_ACCOUNT_ID: ***
/home/runner/work/_temp/….sh: line 1: bun: command not found
##[error]Process completed with exit code 127
The deploy job installs with npm and never set up bun, unlike test.yml and sync-upstream.yml which both use oven-sh/setup-bun@v2. Because the step is continue-on-error: true, the run stayed green and the release quietly fell back to the placeholder.
How
One added step. Nothing else needed:
scripts/generate-ai-changelog.mjsis byte-for-byte identical to the one inCap-go/capacitor-inappbrowser, which produces real changelogs today, so the script, model, and Cloudflare response handling are fine.- Both Cloudflare secrets are already present and non-empty (the run log masks each as
***). - Checkout already uses
fetch-depth: 0, sogit describefinds the previous tag. - The
action-gh-releasebody already consumessteps.changelog.outputs.resultand builds the compare link fromfrom_tag/to_tag.
Kept the plus-specific publish path untouched: npm workspace install, npm run build --workspace=core|cli, and the four-package @capacitor-plus/* publish loop. bump_version.yml and its lerna flow are unchanged, so package CHANGELOG.md files stay lerna-managed. timeout-minutes: 10 is unchanged.
Testing
Reproduced and verified the fix locally against real repo history at tag 8.3.12:
- Confirmed the failure mode in CI logs:
bun: command not found, exit 127, immediately before the release step emitted the placeholder body and the8.3.12...8.3.12link. - Installed bun and ran
bun run changelog:ai, which now resolves and executes the script (Range: 8.3.11..8.3.12), failing only at the Cloudflare call because this sandbox has no credentials. - Stubbed the Cloudflare response and re-ran the script to confirm it writes all three outputs in valid
GITHUB_OUTPUTform, including the heredoc-delimited multiline body:
result<<changelog_1786607743800
## Fixed
- Android inset regression on rotation
changelog_1786607743800
from_tag=8.3.11
to_tag=8.3.12
- Parsed the workflow YAML and confirmed step ordering (checkout → node → bun → install → build → changelog → publish → release) and
timeout-minutes: 10.
Not Tested
- A real tag push. The end-to-end result, including the live Cloudflare Workers AI call, can only be confirmed on the next release.
git diff --statunder thefilter: blob:nonepartial clone relies on lazy blob fetching. It works incapacitor-inappbrowserwith the same checkout options and identical script, but it is untested in this repo's CI.
Authored by an AI agent (Cursor).


Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.
Summary by CodeRabbit
- Chores
- Updated the deployment workflow to prepare the required runtime before generating AI-assisted changelogs.