Run npm run check:all if available and resolve all issues found
Runs `npm run check:all` to find and fix all code quality issues. Use this to resolve type errors, linting problems, and test failures systematically.
/plugin marketplace add sjungling/claude-plugins/plugin install workflow@claude-pluginsYou are tasked with running quality checks and resolving all issues found. Follow these steps:
flowchart TD
Start([Start]) --> DetectEnv[Run npm run to list scripts]
DetectEnv --> HasScript{check:all available?}
HasScript -->|No| AskUser[Ask about alternative scripts]
HasScript -->|Yes| RunChecks[Run npm run check:all]
RunChecks --> ParseOutput[Parse errors, warnings, failures]
ParseOutput --> CreateTodos[Create TodoWrite list for all issues]
CreateTodos --> HasIssues{Issues found?}
HasIssues -->|No| Success[All checks pass]
HasIssues -->|Yes| NextIssue[Get next issue from todo]
NextIssue --> MarkInProgress[Mark todo as in_progress]
MarkInProgress --> ReadCode[Read affected files]
ReadCode --> UnderstandIssue[Analyze root cause]
UnderstandIssue --> FixIssue[Apply targeted fix with Edit]
FixIssue --> Verify[Re-run npm run check:all]
Verify --> FixWorked{Issue resolved?}
FixWorked -->|Yes| MarkComplete[Mark todo as completed]
FixWorked -->|No| Attempts{Attempts < 3?}
Attempts -->|Yes| TryAgain[Try alternative approach]
TryAgain --> ReadCode
Attempts -->|No| MarkBlocked[Mark as blocked, ask user]
MarkComplete --> MoreIssues{More issues?}
MarkBlocked --> MoreIssues
MoreIssues -->|Yes| NextIssue
MoreIssues -->|No| FinalCheck[Run full npm run check:all]
FinalCheck --> AllPassed{All checks pass?}
AllPassed -->|No| NewIssues[Add new issues to todo]
NewIssues --> NextIssue
AllPassed -->|Yes| Summary[Provide completion summary]
Summary --> End([End])
Success --> End
AskUser --> End
style Start fill:#90EE90
style End fill:#90EE90
style Success fill:#90EE90
style MarkBlocked fill:#FFB6C1
style AllPassed fill:#87CEEB
First, check if this is a Node.js project and if the check:all script is available:
npm run to list all available scriptscheck:all is in the outputIf npm run check:all is available:
Run the check command:
npm run check:all
Capture and analyze output:
Create a task plan using TodoWrite:
For each issue found:
Read affected files:
Fix the issue:
Verify the fix:
npm run check:all to confirm the issue is resolvedMove to next issue:
After resolving all issues:
Run full check suite:
npm run check:all
Verify clean output:
Summary:
npm run format or similar if availableIf a fix creates new issues:
If stuck on an issue for more than 2-3 attempts:
Proceed with running the checks and resolving all issues found.