ci: lint GitHub actions with actionlint#516
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
📝 WalkthroughWalkthroughAdded actionlint linting to CI and local tooling (new Changes
Sequence Diagram(s)sequenceDiagram
participant Runner as GitHub Actions Runner
participant Repo as Repository (checkout)
participant Fetch as download-actionlint.bash
participant ReleaseHost as Releases (github.com)
participant Actionlint as actionlint binary
Runner->>Repo: actions/checkout
Runner->>Fetch: run download-actionlint.bash (v1.7.12)
Fetch->>ReleaseHost: request actionlint v1.7.12
ReleaseHost-->>Fetch: deliver binary
Fetch-->>Runner: set outputs.executable
Runner->>Actionlint: execute `${{ steps.get_actionlint.outputs.executable }} -color` on repo workflows
Actionlint-->>Runner: exit status / diagnostics
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.github/workflows/ci.yaml:
- Around line 104-107: The workflow step "Download actionlint" (id
get_actionlint) currently fetches the installer from the mutable main branch;
update the curl invocation to pin the installer to the same release used by
.pre-commit-config.yaml (v1.7.12) by changing the URL to
raw.githubusercontent.com/rhysd/actionlint/v1.7.12/scripts/download-actionlint.bash
and harden the download with fail-fast curl flags (e.g. -fsSL or --fail --silent
--show-error) so the workflow is reproducible and fails fast on network errors.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: a0174d2b-4ce5-423a-95ce-31aeaf7fe3c6
📒 Files selected for processing (4)
.github/workflows/ci.yaml.github/workflows/release.yaml.pre-commit-config.yamlCONTRIBUTING.md
Check list
Description
Add a CI job and pre-commit hook to lint our GitHub actions using
actionlint. Also adds shfmt as developer dependency in CONTRIBUTING.md, which I forgot to do in #514. This should be the final part of my quest to improve our CI.Type of change
Summary by CodeRabbit