ワンクリックで
fix-linter-test
Debug and fix a failing MegaLinter linter test. Use when a linter test fails in CI or locally.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Debug and fix a failing MegaLinter linter test. Use when a linter test fails in CI or locally.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Run the pr-watch-fix loop in parallel across every open Renovate-bot PR, each in its own git worktree. Use to green-light or triage all dependency-update PRs at once.
Handle CVE/vulnerability reports from security linters (trivy, osv-scanner, etc.). Tries to upgrade first; ignores only when safe and justified; disables an unmaintained linter (with user confirmation) when a dangerous CVE has no fix.
Watch the GitHub PR for the current branch, wait for CI to finish, and autonomously fix failing jobs by reading logs, editing sources, and pushing. Stops cleanly when stuck.
Prepare a MegaLinter release — update CHANGELOG (prune empty sections, collapse linter versions, backfill PR numbers), run the release build, push commit and tag, and guide GitHub release creation.
Add a new MegaLinter flavor (language-specific Docker image). Use when creating a new specialized Docker image variant.
Guided workflow for adding a new linter to MegaLinter. Use when a contributor needs to add support for a new linting tool.
| name | fix-linter-test |
| description | Debug and fix a failing MegaLinter linter test. Use when a linter test fails in CI or locally. |
| allowed-tools | Read Grep Glob Bash Edit |
| argument-hint | ["linter-name-or-test-output"] |
| model | sonnet |
Debug the failing test for $ARGUMENTS.
Steps:
megalinter/tests/test_megalinter/linters/@generated by .automation/build.py header) — if so, fix the descriptor YAML or fixtures, NOT the test file itselfmegalinter/descriptors/ to understand expected behavior (cli_lint_mode, config_file_name, cli_lint_errors_regex, file_extensions).automation/test/<test_folder>/:
cli_lint_errors_regexfile_extensions or file_names_regex in the descriptormegalinter/linters/, review it for issuesfile_extensionscli_lint_errors_regex doesn't match actual linter output formatconfig_file_namecli_lint_mode mismatch (file vs list_of_files vs project)LINTER="<descriptor_id_lowercase>_<linter_name>"
docker buildx build --platform linux/amd64 --file linters/$LINTER/Dockerfile --tag $LINTER .
docker run --rm --env TEST_CASE_RUN=true --env OUTPUT_DETAIL=detailed \
--env TEST_KEYWORDS="${LINTER}_test" --env MEGALINTER_VOLUME_ROOT="." \
--volume "$(pwd):/tmp/lint" $LINTER
To run only a specific test method (e.g., test_failure):
--env TEST_KEYWORDS="${LINTER}_test and test_failure"
TEST_KEYWORDS=<linter>_testCHANGELOG.md only if the fix changes user-visible linter behavior (wrong error count, missed files, broken output). Add one line under Fixes in the beta section:
- Fix <linter-name>: <what was wrong and what users now get>
Do NOT add an entry for test-infrastructure-only fixes (fixture paths, test class regeneration, etc.).