prune-code-comments
БесплатноБез исполняемых скриптовНе проверенAudit or prune source-code comments across a codebase or a specified area. Use when asked to remove redundant or stale comments, turn workarounds into issues…
от narumiruna★ 19 звёзд на GitHubОб этом скилле
Prune Code Comments
Review every source comment in the requested scope using a tokenizer or parser for each language. Keep required notices, tool directives, and public API documentation; defer comments whose meaning is unclear. If asked only to audit, plan, or estimate, do not make changes.
Classify and Act
| Category | Meaning | Action |
|---|---|---|
| Tautology | Repeats what the code already shows. | Delete it. |
| Excuse | Justifies a workaround that still needs a fix. | Capture it in a follow-up issue before deleting the comment; leave the workaround unchanged. |
| Stale | Describes something that no longer applies. | Verify, then delete it. |
| Decision Record | Explains an important, non-obvious choice. | Move the rationale to an architecture decision record (ADR) before deleting the comment. |
Reuse an existing issue or draft one if filing is not authorized. Keep the comment if deleting it would lose a live warning with no durable handoff.
Enforce the Ban
Use a syntax-aware linter for the same scope, implemented in a language that fits the project’s tooling. Add it to the project's pre-commit hook setup. Baseline only the remaining non-exempt comments and shrink the baseline as they are removed. Reject new or edited comments, even if the total stays the same, and do not allow the baseline to grow after setup. Verify through the hook that retained comments pass and new or replacement comments fail.
Report
Summarize category counts, exceptions, deferrals, issue and ADR references, and verification results. Report the all-comments upper bound, the estimated removable lines, and the actual lines removed. Count only physical source lines occupied entirely by comments: removing an inline comment does not save a line.
Установить prune-code-comments в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл prune-code-comments?
Audit or prune source-code comments across a codebase or a specified area. Use when asked to remove redundant or stale comments, turn workarounds into issues, move decision rationale into ADRs, enforce a gradual ban on new comments, or estimate how many source lines comment removal would save. Not for PR review comments or ordinary code review.
Как установить скилл prune-code-comments?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл prune-code-comments запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic