add-check
Add a new code quality check to CI, justfile, and pre-commit hooks. Use when adding linters, formatters, type checkers, or other code quality tools to the project.
When & Why to Use This Skill
This Claude skill automates the integration of code quality tools into your development workflow. It streamlines the process of adding linters, formatters, and type checkers to your CI/CD pipeline, local task runners (justfile), and pre-commit hooks (lefthook), ensuring consistent code standards and reducing manual configuration errors across the project.
Use Cases
- Integrating a new Python linter like Ruff into a project's existing GitHub Actions pipeline and local environment.
- Setting up automated type checking with Mypy to run both locally via pre-commit hooks and during remote verification builds.
- Ensuring consistent code formatting by adding a formatter like Black or Prettier to the project's 'just' recipes and CI verification workflows.
- Standardizing project-wide quality gates by synchronizing local development checks with cloud-based continuous integration steps.
| name | add-check |
|---|---|
| description | Add a new code quality check to CI, justfile, and pre-commit hooks. Use when adding linters, formatters, type checkers, or other code quality tools to the project. |
Adding a New Check
When adding a new code quality check (linter, formatter, type checker, etc.), update these three locations:
1. justfile
Add a new recipe and include it in the default target:
default: lint format typecheck your-check
your-check:
uv run YOUR_COMMAND
2. .github/workflows/ci.yaml
Add a step to the verify job after the existing checks:
- name: Run YOUR_CHECK
run: uv run YOUR_COMMAND
3. lefthook.yml
Add a job to the pre-commit.jobs list:
- name: YOUR_CHECK
glob: "*.py"
run: YOUR_COMMAND {staged_files}
If the tool can auto-fix issues, add stage_fixed: true.
Checklist
- Add dev dependency to
pyproject.tomlif needed - Add justfile recipe and update
defaulttarget - Add CI workflow step
- Add lefthook pre-commit job
- Run
justto verify all checks pass