.claude/skills/review-code-quality/SKILL.md
Review code quality — separation of concerns, magic numbers, DRY, maintenance issues
npx skillsauth add cwilliams5/Alt-Tabby review-code-qualityInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Enter planning mode. Deep-review the codebase for code quality and maintainability issues. Use maximum parallelism — spawn explore agents for independent areas.
Sleep(150) — what does 150 mean?)0, 1, true, false, or well-known Windows constants in DllCall are finesrc/core/ and touching window store data is by design, not a concern violationDo NOT flag functions for refactoring based on line count alone. Length is not a quality issue.
SKIP refactoring when the function has:
RECOMMEND refactoring only when:
Risk/reward check before recommending any refactor:
Split by area for parallel scanning:
src/gui/ — GUI rendering, state machine, overlay, inputsrc/core/ — Producers (WinEventHook, Komorebi, pumps)src/shared/ — Window list, config, IPC, blacklist, theme, statssrc/editors/ — Config/blacklist editorssrc/pump/ — EnrichmentPump subprocesssrc/ files — Entry points, launcher, installation, updateExclude src/lib/ (third-party code).
Use query_interface.ps1 to compare module public surfaces — similar API shapes across files can reveal DRY violations or misplaced responsibilities. Use query_function.ps1 <funcName> to read function bodies when evaluating DRY violations without loading full files. Use query_callchain.ps1 <funcName> -Reverse to trace callers when checking whether misplaced logic is called from the expected module or from elsewhere.
After explore agents report back, validate every finding yourself. Code quality is subjective — what looks like a concern violation may be an intentional design choice for performance or simplicity.
For each candidate:
file.ahk lines X–Y" with actual code quoted.Group by category:
| Category | File | Lines | Issue | Fix | Counter-argument |
|----------|------|-------|-------|-----|-----------------|
| Magic number | foo.ahk | 42 | Sleep(150) — grace period, no named constant | Extract to cfg.GracePeriodMs or named constant | Only used once, comment explains it |
| DRY | bar.ahk:30, baz.ahk:55 | Duplicate pipe cleanup logic | Extract shared helper | Both are 5 lines, abstraction may not be worth it |
Order by maintenance impact: issues that make future changes error-prone first, purely cosmetic issues last.
Ignore any existing plans — create a fresh one.
tools
Create a new git worktree and switch the session into it
tools
Spawn agent to trace code flow via query tools — answer only, no context cost
tools
Commit, push, and create a PR for the current branch
tools
Retire a shader by moving its files to legacy/shaders_retired