commit
Create git commits with user approval and no Claude attribution
Fix linting and type errors in files changed on the current branch, with sequential resolution
$ npx -y skills add dcouple/Pane --agent claude-codeHow it fires
How this command gets triggered: by you, by Claude, or both.
/local-changesContext preview
What this command does when you run it.
Fix linting and type errors in files changed on the current branch, with sequential resolution
allowed-tools: Read, Edit, Bash(git diff:*), Bash(npm run typecheck:*), Bash(npm run lint:*), Bash(npx nx typecheck:*), Bash(npx nx lint:*), Bash(npx tsc:*), Bash(npx eslint:*), TodoWrite, Grep description: Fix linting and type errors in files changed on the current branch, with sequential resolution
Fix TypeScript type errors and ESLint warnings in files that have been modified on the current branch. This is a focused alternative to `/fix-issues` that only processes local changes and fixes issues sequentially.
First, get the list of files modified on the current branch:
# Get files changed compared to main branch git diff --name-only main...HEAD # Also check unstaged/staged changes git diff --name-only git diff --cached --name-only
Combine and deduplicate the results. Filter to only TypeScript/TSX files:
If there are no TypeScript files changed, inform the user and exit.
For each changed file, run diagnostics:
**TypeScript Type Checking:**
IMPORTANT: Use the TypeScript compiler (`tsc`) rather than relying on VS Code's language server, as it's more authoritative and doesn't have caching issues.
# For webapp files - run full project check, then filter to changed files npx tsc --noEmit --project apps/webapp/tsconfig.json 2>&1 | grep -E "error TS" # For API files - run full project check, then filter to changed files npx tsc --noEmit --project apps/api/tsconfig.json 2>&1 | grep -E "error TS" # For shared library files npx tsc --noEmit --project libs/shared/tsconfig.json 2>&1 | grep -E "error TS"
Parse the TypeScript output to extract errors. Each error line follows this format:
path/to/file.ts(line,col): error TS####: Error message
Filter the errors to only include files from the changed files list.
**ESLint:**
# Run eslint on specific files npx eslint <file1> <file2> <file3> --max-warnings=0
Collect all issues with:
**Note:** The TypeScript compiler output is the source of truth. VS Code's inline diagnostics can show false positives due to caching issues with dynamic imports and path aliases.
Use TodoWrite to create a structured plan with one todo per issue (or group related issues):
Example todos: - Fix TS2532 error in file.ts:42 - 'foo' is possibly undefined - Remove unused import 'Bar' in file.ts:5 - Fix React Hook dependency array in component.tsx:89 - Add proper type annotation to function in service.ts:123
Order todos by: 1. Critical type errors first 2. Then other TypeScript errors 3. Then ESLint warnings 4. Group issues in the same file together when possible
**DO NOT use subagents or parallel execution.** Fix issues one by one:
1. **Mark as in_progress** using TodoWrite 2. **Read the file** to understand context 3. **Apply the fix** using Edit tool 4. **Verify the fix** by running typecheck/lint on that specific file 5. **If successful**: Mark todo as completed and move to next 6. **If failed**: Try alternative fix or mark with error note
**Type Errors (TS2xxx):**
**ESLint Issues:**
**Common Patterns:**
After all issues are fixed:
# Run full typecheck for affected projects using TypeScript compiler (source of truth) npx tsc --noEmit --project apps/webapp/tsconfig.json 2>&1 | grep -E "error TS" npx tsc --noEmit --project apps/api/tsconfig.json 2>&1 | grep -E "error TS" # Alternative: Use nx typecheck commands npx nx typecheck @doozy/webapp npx nx typecheck @doozy/api # Run lint on changed files npx eslint <all-changed-files> --max-warnings=0
Report:
Provide a concise summary:
✓ Fixed 15 issues across 8 files: - 7 TypeScript type errors - 5 unused imports removed - 3 React Hook dependency warnings Modified files: - apps/webapp/src/components/TodoCard.tsx - apps/webapp/src/hooks/useStartTodoConversation.ts ... ✓ All files now pass typecheck and lint (verified with tsc compiler) Note: If VS Code still shows red underlines, restart the TypeScript server: Ctrl+Shift+P → "TypeScript: Restart TS Server"
Handle optional arguments if provided:
1. **Only touch changed files** - Don't scan entire codebase 2. **Sequential execution** - Fix one issue at a time
Repo: dcouple/Pane
Create git commits with user approval and no Claude attribution
You are tasked with creating detailed implementation plans through an interactive, iterative process. You should be skeptical, thorough, and work…
Generate comprehensive PR descriptions following repository templates
You are tasked with implementing an approved technical plan from `thoughts/shared/plans/`. These plans contain phases with specific changes and success…
Iterate on existing implementation plans with thorough research and updates
You are tasked with conducting comprehensive research across the codebase to answer user questions. You will spawn one or more parallel sub-agents to perform…