技能 clean-code-reviewer
🔍
clean-code-reviewer
安全 ⚙️
外部命令🌐
網路存取
使用 Clean Code 原則審查程式碼品質
程式碼審查有助於在維護性問題變成技術債務之前加以識別。本技能為 AI 助手提供系統化的指南,以評估程式碼的七個關鍵維度,包括命名、函式、重複和專案慣例。
支援: Claude Codex Code(CC)
1
下載技能 ZIP
2
在 Claude 中上傳
前往 設定 → 功能 → 技能 → 上傳技能
3
開啟並開始使用
測試它
正在使用「clean-code-reviewer」。 Review my codebase for code quality issues
預期結果:
- Found 3 high severity issues:
- • users.ts:23 - Vague naming: 'temp' instead of 'temporaryFilePath'
- • orders.ts:45 - Function exceeds 100 lines (145 lines)
- • utils.ts:89 - Duplicate validation logic (similar to utils.ts:112)
- Medium severity: 2 magic numbers without constants
- Low severity: 1 import ordering issue
安全審計
安全v4 • 1/17/2026
All 121 static findings are FALSE POSITIVES. This skill contains only documentation (markdown files) with educational code examples. The static analyzer misidentified TypeScript/JavaScript code examples inside markdown code fences as security threats. No executable code, network calls, or file system operations exist.
5
已掃描檔案
2,019
分析行數
2
發現項
4
審計總數
風險因素
審計者: claude 查看審計歷史 →
品質評分
41
架構
100
可維護性
81
內容
34
社群
100
安全
91
規範符合性
你能建構什麼
提交前程式碼審查
審查合併請求以早期發現維護性問題
舊程式碼評估
系統性評估現有程式碼庫的技術債務並優先重構
自動化程式碼回饋
在開發工作流程中提供一致的程式碼品質回饋
試試這些提示
基本審查
Use /clean-code-reviewer to analyze my code and identify issues with naming, functions, and code duplication.
模組審查
Use /clean-code-reviewer --scope=components to review all UI components for naming and structure issues.
慣例檢查
Use /clean-code-reviewer --dimension=conventions to verify import ordering and naming consistency.
平行團隊審查
Split the codebase using /clean-code-reviewer with parallel agents by language (TypeScript, Python, Go).
最佳實務
- 提供程式碼庫上下文和 CLAUDE.md 或 AGENTS.md 以了解專案特定慣例
- 使用嚴重性等級來優先處理開發團隊的問題
- 對於大型程式碼庫,結合按維度和按模組的平行代理程式
避免
- 要求功能變更而非實作改進
- 忽視文件中定義的專案特定慣例
- 將每個問題都標記為高嚴重性會削弱重要發現的影響力
常見問題
此技能支援哪些語言?
提供了 TypeScript、JavaScript、Python 和 Go 的範例。原則廣泛適用。
此技能會執行程式碼嗎?
不,這是基於程式碼模式和慣例的靜態分析審查。
如何確定嚴重性等級?
高影響會立即影響可維護性,中等表示有改進空間,低是選用性的。
可以自訂閾值嗎?
可以,請參考 CLAUDE.md 或 AGENTS.md 中的專案慣例進行自訂。
它會檢查安全問題嗎?
不,重點在於程式碼品質和可維護性,而非安全漏洞。
如何處理大型程式碼庫?
使用按維度、模組、語言或檔案類型分割的平行代理程式來提高效率。