lint-fix
npx machina-cli add skill yu-iskw/google-cloud-observability-plugin/lint-fix --openclawFiles (1)
SKILL.md
807 B
Lint Fix
Run formatting and lint checks using the project Makefile.
Workflow
- Run
make formatto format code. - Run
make lintto check for violations. - Address any remaining lint failures manually if needed.
Usage
When lint or format issues are detected or when you need to ensure code quality:
- Run
make formatthenmake lint.
Progressive Disclosure
- Makefile target definitions: Makefile at repo root.
Related Skills
- Plugin verification:
../plugin-verification/SKILL.md - Agent skills implementation:
../implement-agent-skills/SKILL.md
Sources
Source
git clone https://github.com/yu-iskw/google-cloud-observability-plugin/blob/main/.claude/skills/lint-fix/SKILL.mdView on GitHub Overview
lint-fix streamlines code quality by applying formatting with make format and checking style with make lint. It helps ensure consistent formatting and lint compliance before commits or PRs, and guides you to manually fix any remaining issues.
How This Skill Works
It runs two Makefile targets in sequence: format to auto-fix style issues, and lint to surface code quality violations. If lint reports failures, you fix them in code and can re-run the targets until clean.
When to Use It
- Before committing or opening a pull request to ensure formatting is applied.
- After pulling changes to re-align local formatting with the repository.
- When CI reports lint violations locally during development.
- When starting work on a new file or module to enforce style from the outset.
- During pre-release checks to verify overall code quality.
Quick Start
- Step 1: Run make format.
- Step 2: Run make lint.
- Step 3: Fix any remaining issues manually if needed.
Best Practices
- Always run make format before make lint.
- Review the lint output carefully and address the root cause.
- Re-run both targets after each significant edit.
- Keep Makefile targets up to date with project standards.
- Document any forced exceptions or tool-specific configurations.
Example Use Cases
- A contributor runs make format and make lint after editing a file.
- A PR build passes locally by addressing lint failures.
- A maintainer fixes indentation and trailing whitespace flagged by lint.
- CI workflow uses lint-fix to catch issues before merge.
- After upgrading the lint tool, the team re-runs make format and make lint to validate changes.
Frequently Asked Questions
Add this skill to your agents