Before pushing a workflow file, which tool can you use locally to validate the YAML syntax?
Select an answer to reveal the explanation.
Short Explanation and Infographic
actionlint is the community-built static analyzer for GitHub Actions — it catches syntax errors, typos, and logic issues before you push.
Full explanation below image
Full Explanation
actionlint is a static analysis tool specifically for GitHub Actions workflow files. It checks YAML syntax, validates GitHub Actions-specific fields, detects common mistakes (wrong context names, incorrect syntax for 'if' conditions, unknown action inputs), and can detect some security issues like script injection patterns. Install via brew, go install, or download binary. Run: 'actionlint .github/workflows/ci.yml'. 'github-lint' doesn't exist. 'yaml-validator --github' doesn't exist. 'gh workflow validate' is not a valid gh CLI subcommand (as of 2024). GitHub's own linting only happens server-side after pushing.