From imbue-code-guardian
Automatically find and fix code issues in the current branch. Iteratively verifies, plans fixes, and implements them with separate commits. Defers all review to the end.
npx claudepluginhub imbue-ai/code-guardian --plugin imbue-code-guardianThis skill is limited to using the following tools:
Iteratively verify the current branch for code issues, plan and implement fixes (each in a separate commit), and repeat until clean. At the end, present each fix for user review and revert any the user does not want.
Guides Next.js Cache Components and Partial Prerendering (PPR) with cacheComponents enabled. Implements 'use cache', cacheLife(), cacheTag(), revalidateTag(), static/dynamic optimization, and cache debugging.
Guides building MCP servers enabling LLMs to interact with external services via tools. Covers best practices, TypeScript/Node (MCP SDK), Python (FastMCP).
Generates original PNG/PDF visual art via design philosophy manifestos for posters, graphics, and static designs on user request.
Iteratively verify the current branch for code issues, plan and implement fixes (each in a separate commit), and repeat until clean. At the end, present each fix for user review and revert any the user does not want.
Autofix requires a clean git state. Before proceeding, check for uncommitted changes:
git status --porcelain
If there are any untracked, staged, or unstaged changes, commit them first (or add them to .gitignore if they should not be tracked). Do NOT proceed until git status --porcelain produces no output.
initial_head): !git rev-parse HEADbase_branch): !echo "${GIT_BASE_BRANCH:-main}"If you do not already know what the changes on this branch are supposed to accomplish, STOP and ask the user before continuing.
Write a brief description of what the branch is trying to do. This helps the diff validation and fix agents distinguish intentional changes from issues.
Spawn a validate-diff Agent. Provide the base branch name and the problem description.
Based on the agent's response:
Repeat up to 10 times:
pre_iteration_head..reviewer/outputs/autofix/issues/{pre_iteration_head}.jsonlverify-and-fix Agent, providing the base branch ({base_branch}), the full current HEAD hash ({pre_iteration_head}), and the issue categories path: .reviewer/code-issue-categories.md if it exists, otherwise ${CLAUDE_PLUGIN_ROOT}/agents/categories/code-issue-categories.md.git rev-parse HEAD to pre_iteration_head.Important:
verify-and-fix agent task to finish--do not simply finish your response!After the loop ends:
git log --reverse --format="%H %s" {initial_head}..HEAD.reviewer/autofix/auto-accept.md exists. If it does, read it. This file contains free-text rules describing which kinds of fixes should be automatically accepted without prompting the user (e.g. "accept all naming fixes", "auto-accept anything in test files").AskUserQuestion call. Use one question per commit (up to 4 per call; if there are more than 4 commits, use multiple calls but still gather all answers before doing any git operations). Each question should:
git revert --no-edit {hash} for each, in reverse chronological order (newest first) to avoid conflicts..reviewer/outputs/autofix/issues/*.jsonl files).For this particular run of the autofix command, follow these adjustments from the user to the normal process:
$ARGUMENTS