linting-workflow-skill
Skill7 starsChanged 56 days agoApache-2.0View on GitHub
Lint execution workflow — detect configs, run linters, auto-fix, resolve errors across languages. Triggers: lint, auto-fix lint. Per-language rules and configs: language-linting-skill; executor agent: linting-subagent. Gate sequence and pass semantics: verification-loop-skill.
- Reads credentials
- Deletes or force-pushes
- Installs packages
- Commits and pushes
In this repository85 other files it gives its agents.
- AGENTS.mdAGENTS.md
- accessibility-a11y-skillSkill
- agent-introspection-debugging-skillSkill
- amplify-nextjs-deployment-skillSkill
- architecture-review-skillSkill
- authentication-authorization-skillSkill
- autoresearch-skillSkill
- aws-iac-safety-skillSkill
- blast-radius-skillSkill
- browser-fallback-skillSkill
- cad-dxf-skillSkill
- cad-generation-skillSkill
- cad-implicit-skillSkill
- cad-redraw-skillSkill
- cad-specialist-skillSkill
- cad-viewer-skillSkill
- changelog-python-cliff-skillSkill
- civiltekk-api-spec-skillSkill
- civiltekk-coding-harness-setup-skillSkill
- civiltekk-context-optimization-skillSkill
- civiltekk-diagram-skillSkill
- civiltekk-documentation-inline-skillSkill
- civiltekk-documentation-sync-skillSkill
- civiltekk-git-commits-skillSkill
- civiltekk-nextjs-skillSkill
- referencesSkill
- civiltekk-opencode-creation-skillSkill
- civiltekk-opentofu-skillSkill
- civiltekk-ponytail-audit-skillSkill
- civiltekk-pr-workflow-skillSkill
- civiltekk-python-backend-skillSkill
- civiltekk-react-quality-skillSkill
- civiltekk-startup-docs-skillSkill
- civiltekk-test-generation-skillSkill
- civiltekk-zai-media-skillSkill
- code-principles-skillSkill
- code-review-inline-skillSkill
- construction-bd-skillSkill
- continuous-learning-skillSkill
- coverage-readme-workflow-skillSkill
- database-migration-skillSkill
- deprecated-code-cleanup-skillSkill
- docker-containerization-skillSkill
- domain-modeling-skillSkill
- email-drafter-skillSkill
- error-resolver-workflow-skillSkill
- eval-harness-skillSkill
- frontend-design-skillSkill
- gh-cli-setup-skillSkill
- grilling-skillSkill
- gsap-skillSkill
- horseshoe-paper-writing-skillSkill
- install-assistant-skillSkill
- language-linting-skillSkill
- language-review-checklists-skillSkill
- linting-inline-skillSkill
- logging-observability-skillSkill
- monorepo-management-skillSkill
- office-document-router-skillSkill
- opencode-repo-setup-skillSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
9 rules. About 0 are common, 8 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈8
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
Run linting and apply auto-fix when available
- Distinctive: line 17
Verify fixes and commit changes
- Distinctive: line 95
Use error messages for guidance
- Distinctive: line 114
Run linting before committing
- Distinctive: line 117
Don't disable rules as workaround
- Distinctive: line 120
Use pre-commit hooks (Husky, pre-commit)
- Distinctive: line 144
Check if rule supports auto-fix
- Distinctive: line 153
Auto-detection: if this skill is invoked on a task that looks iterative (multiple cycles expected), prompt ONCE per session: "This looks …
- Very specific: line 159
Git-as-memory: commit before each verify.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
What I do
I provide a generic linting workflow for multiple languages:
- Detect project language and linter configuration
- Run linting and apply auto-fix when available
- Guide resolution of linting errors
- Verify fixes and commit changes
When to use me
Use when:
- Linting code before committing or PRs
- Building workflow skills with code quality checks
- Need consistent linting across multiple languages
This is a framework skill - provides linting logic that other skills extend.
Steps
Step 1: Detect Language and Linter
Detection:
package.json+tsconfig.json→ TypeScript (ESLint)package.json→ JavaScript (ESLint)pyproject.toml/requirements.txt→ Python (Ruff)go.mod→ Go (golint/golangci-lint)Gemfile→ Ruby (RuboCop)
Configuration files:
- ESLint:
eslint.config.ts/js/mjs,.eslintrc.json/js/yaml - Ruff:
pyproject.toml,.ruff.toml,ruff.toml
Step 2: Detect Package Manager
| Language | Manager | Lock File | Command |
| JS/TS | npm | package-lock.json | npm run <script> |
| JS/TS | yarn | yarn.lock | yarn <script> |
| JS/TS | pnpm | pnpm-lock.yaml | pnpm run <script> |
| Python | Poetry | pyproject.toml | poetry run <script> |
| Python | pip | requirements.txt | Direct command |
Step 3: Run Linting
Commands:
# JavaScript/TypeScript (ESLint)
npm run lint # npm
yarn lint # yarn
pnpm run lint # pnpm
npx eslint . # direct
# Python (Ruff)
ruff check . # direct
poetry run ruff check . # poetryStep 4: Apply Auto-Fix
Auto-fix commands:
- ESLint:
npm run lint -- --fix - Prettier:
npx prettier --write . - Ruff:
ruff check . --fix - Black:
black .
Auto-fix capabilities:
- Style violations, unused variables, simple syntax issues
- Formatting, indentation, quotes
- Unused imports, simple refactorings
Step 5: Fix Remaining Errors
Error categories:
- Syntax errors (prevents code from running)
- Style violations (code style guidelines)
- Potential bugs (risky code patterns)
- Deprecation warnings (deprecated features)
- Type errors (TypeScript type mismatches)
- Missing docstrings (public functions/classes)
Resolution workflow:
- Run auto-fix first
- Fix remaining errors incrementally
- Re-run linting after each batch
- Use error messages for guidance
Step 6: Verify and Commit
Re-run linting:
# Re-check after manual fixes
npm run lint # or
ruff check .Commit fixes:
git add .
git commit -m "fix(lint): resolve linting errors"Best Practices
- Run linting before committing
- Apply auto-fix before manual fixes
- Fix errors incrementally, re-run between batches
- Don't disable rules as workaround
- Configure editor to lint on save
- Integrate into CI/CD pipelines
- Use pre-commit hooks (Husky, pre-commit)
Common Issues
Linter Not Found
Install linter:
npm install --save-dev eslint # ESLint
pip install ruff # RuffConfig File Missing
Create default config:
- ESLint:
.eslintrc.jsonwith{"extends": "eslint:recommended"} - Ruff:
pyproject.tomlwith[tool.ruff] line-length = 88
Too Many Errors
- Focus on one category at a time
- Fix incrementally
- Re-run after each batch
Auto-Fix Doesn't Work
- Some errors require manual intervention
- Review error messages
- Check if rule supports auto-fix
Iteration Protocol (opt-in)
DO NOT execute any of the following unless AUTORESEARCH_PROTOCOL=1 is set in your environment. When unset, this skill behaves exactly as documented in all sections above; the Iteration Protocol block is descriptive only.
When AUTORESEARCH_PROTOCOL=1:
- Gate check: confirm env var is set; if unset, follow default behavior above.
- Auto-detection: if this skill is invoked on a task that looks iterative (multiple cycles expected), prompt ONCE per session: "This looks iterative. Enable autoresearch protocol? (y/n)". On "y", continue; on "n", default behavior. Cache the answer for the session.
- 5-stage loop: cycle Understand → Hypothesize → Experiment → Evaluate → Log & Iterate. See
autoresearch-skill/SKILL.md. - Evaluator contract: emit
{"pass":bool,"score":N}JSON from a mechanical evaluator. Pass determines keep/revert; score logged tolinting-results.tsv. Seeautoresearch-skill/references/evaluator-contract.md. - Stuck detection: 3 consecutive non-improving iterations → strategy pivot; 5 consecutive → paradigm shift. See
autoresearch-skill/references/stuck-detection.md. - Audit trail: append every iteration to
linting-results.tsv(8-column: iteration, commit, metric, delta, status, description, timestamp, evaluator_output). Seeautoresearch-skill/references/audit-trail.md. - Crash recovery: syntax errors → fix immediately (don't count); runtime → max 3 fix attempts then skip; timeout → revert + log; OOM → smaller variant. See
autoresearch-skill/references/crash-recovery.md. - Git-as-memory: commit before each verify; auto-revert (
git reset --hard HEAD~1) onpass:false. - Iteration safety: bounded-by-default (
Iterations: 25); safety blocks.env,node_modules/,rm -rf,git push --force. Seeautoresearch-skill/references/iteration-safety.md.
Skill-specific override
Stuck detection + crash recovery. 3 consecutive iterations without reducing lint-error-count → pivot to a different rule category (e.g., from E to W, or from style to type). Crash recovery: syntax errors introduced by auto-fix → revert immediately (don't count as iteration); rule conflicts → skip rule, log to linting-results.tsv.
Max iterations
- Default: 25 iterations
- Hard cap: 100 (explicit
Iterations: unlimitedoverrides)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

