Agent skill
lint-and-fix
Run make format and make lint, then fix linter violations. Use when formatting code or fixing trunk/lint issues.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/data/lint-and-fix-yu-iskw-github-project-skill
SKILL.md
Lint-and-Fix
Purpose
An autonomous loop to format the codebase, run linters, and fix any remaining violations until the project passes format and lint checks.
Loop Logic
- Format: Run
make format(trunk fmt). - Identify: Run
make lintto list current failures. - Analyze: Read the linter output and the affected code.
- Fix: Apply the minimum necessary change to resolve each issue.
- Verify: Re-run
make formatandmake lint.- If both pass: Done.
- If failures remain: Repeat from step 2 (or move to the next issue).
Termination Criteria
- No failures from
make lintafter fixes. - Optional: Cap iterations (e.g. 5) to avoid unbounded loops.
Reference
Format and lint commands are defined in the project Makefile: make format runs trunk fmt -a; make lint runs trunk check -a -y.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?