Skip to content

docs(readme): point CI badges at per-branch shim + repair husky hook - #192

Merged
pacphi merged 1 commit into
mainfrom
followup/fix-readme-ci-badges
Apr 26, 2026
Merged

pacphi merged 1 commit into
mainfrom
followup/fix-readme-ci-badges

Conversation

@pacphi

@pacphi pacphi commented Apr 26, 2026

Copy link
Copy Markdown
Owner

Summary

  • README badges previously referenced `ci-v2.yml`/`ci-v3.yml`/`ci-v4.yml` directly. Those workflows live on `main` and are only invoked via `workflow_call` from each branch's `ci.yml` shim, so GitHub had no runs of them on `branch=vX` and every badge rendered "no status". Switched the badges to query the shim workflow (`ci.yml`) on each branch and added a `?query=branch%3AvX` filter to the badge link target.
  • husky pre-commit unconditionally ran `pnpm lint-staged`, which fails on `main` after the v1..v4 reorg because there is no root `package.json`. Made the lint-staged step conditional on the presence of a root manifest and `pnpm` on PATH so docs-only commits stop tripping the hook.

Test plan

  • Renders correctly: badges resolve to the latest shim run per branch (visual check after merge)
  • `git commit` on `main` now succeeds without lint-staged when there's no root `package.json`
  • Verify the v2/v3/v4 badges turn green/red (not "no status") after merge

🤖 Generated with Claude Code

The previous badges referenced ci-v2.yml/ci-v3.yml/ci-v4.yml directly,
but those workflows live on main and are only invoked via
workflow_call from each branch's ci.yml shim. As a result, GitHub had
no runs of ci-vX.yml on the corresponding branch=vX, so every badge
rendered as "no status".

Switch the badges to query the shim workflow (ci.yml) on each branch,
which is where actual runs are recorded. Badge link targets gain a
?query=branch%3AvX filter so clicking through goes straight to the
relevant run history.

Also: skip pnpm lint-staged in the husky pre-commit when there is no
root package.json (true for main after the v1..v4 reorg) so the hook
no longer fails on docs-only commits.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@pacphi
pacphi merged commit dc513f5 into main Apr 26, 2026
6 checks passed
@pacphi
pacphi deleted the followup/fix-readme-ci-badges branch April 26, 2026 18:58
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.

1 participant