Skip to content

ci: pin actions to commit SHAs, add Dependabot for them - #739

Merged
cubehouse merged 1 commit into
mainfrom
chore/ci-pin-actions
Dec 5, 2026
Merged

cubehouse merged 1 commit into
mainfrom
chore/ci-pin-actions

Conversation

@cubehouse

Copy link
Copy Markdown
Member

Routine CI maintenance: pin the actions and let Dependabot keep them current.

Changes

  • Actions pinned to commit SHAs. Every uses: in the three workflows names a full commit SHA with the tag in a trailing comment. A tag can be moved to different code; a SHA cannot. This matters most for peaceiris/actions-gh-pages in docs.yml, which is handed the Pages deploy key.
  • Dependabot for actions. .github/dependabot.yml gains a github-actions entry, weekly, one grouped PR. The existing npm entry is unchanged.
  • Workflow token. docs.yml now declares permissions: contents: read at the top level, as the other two workflows already do. Its job-level block is unchanged, and the Pages push uses the deploy key, not the workflow token.
  • Test. src/__tests__/workflows.test.ts holds the above in place.
Action Old ref Pinned SHA
actions/checkout v4 11d5960a326750d5838078e36cf38b85af677262
actions/setup-node v4 49933ea5288caeca8642d1e84afbd3f7d6820020
peaceiris/actions-gh-pages v4 84c30a85c19949d7eee79c4ff27748b70285e453

Risk

No behaviour change is intended: each SHA is the commit its tag pointed at when this was written. A mistyped SHA would fail a run at "Set up job". unit_test.js.yml and dev_container.yml run on this PR and exercise two of the pins; docs.yml first runs on merge.

Testing

  • With the workflow changes reverted, the new test file fails (5 failed, 2 passed); with them applied it passes (7 passed). Typecheck and the pre-commit gates pass.
  • All changed YAML parses. The workflows have not been run locally.

🤖 Generated with Claude Code

- every `uses:` names a full commit SHA, with the tag in a trailing comment
- dependabot.yml gains a github-actions entry (weekly, grouped) so the pins
  stay current
- docs.yml declares `permissions: contents: read` at the top level, matching
  the other two workflows
- src/__tests__/workflows.test.ts holds the workflow shape in place

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@cubehouse
cubehouse merged commit e19fd54 into main Dec 5, 2026
5 checks passed
@cubehouse
cubehouse deleted the chore/ci-pin-actions branch December 5, 2026 12:37
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