megalinter-fix

Solid

Fix the errors reported by MegaLinter. Use after megalinter-check found errors, or when the user pastes MegaLinter/CI lint errors and wants them fixed. Applies safe fixes automatically (auto-fix linters first, then guided manual fixes using per-linter fix guides), asks the user when fixing is ambiguous, and can disable rules or linters with user confirmation. Never pushes to the default branch.

Code & Development 14 stars 4 forks Updated today MIT

Install

View on GitHub

Quality Score: 85/100

Stars 20%
39
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# MegaLinter fix Fix the MegaLinter errors you were given (output contract of `megalinter-check`: linter keys, error counts, files, sample error lines). ## 1. Prepare - If the current branch is the default branch (`main`/`master`), create a branch first: `git checkout -b megalinter/fix-<topic>`. - Group the errors by linter key. Handle **blocking** linters (❌) first; mention non-blocking ones (⚠️) to the user but don't fix them unless asked. ## 2. Load the fix guides — lazily For **each failing linter only**, read its fix guide from this skill's directory: `linters/<linter_key_lower>.md` (e.g. `linters/python_ruff.md`). The index is in `linters/README.md`. Each guide contains a generated block (auto-fix support, config/ignore files, rule documentation URLs, tuning variables, known non-lint failure patterns) and researched fix instructions. Never load guides for linters without errors. ## 3. Fix In this order: 1. **Auto-fixable linters** (guide says auto-fix supported): if a container engine is available, run `npx mega-linter-runner --linter <KEY> --fix [failing files...]` (add `--container-engine podman` when using podman; use `npx mega-linter-runner@beta` when `.mega-linter.yml` pins `MEGALINTER_VERSION: beta` — see the version rule in `megalinter-check`). Otherwise apply the underlying tool's documented fix behavior manually. If no engine is installed/running, ask the user first, then follow `container-engine.md` in the `megalinter-check` skill directory. 2. **Manu...

Details

Author
ulises-jeremias
Repository
ulises-jeremias/agent-toolkit
Created
3 weeks ago
Last Updated
today
Language
V
License
MIT

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category