configure-dead-code
БесплатноБез исполняемых скриптовНе проверенInstall and configure dead-code tooling (Knip, Vulture, cargo-machete, deadcode): config, pre-commit, CI. Use when setting up or migrating unused-code…
от laurigates★ 61 звезда на GitHubОб этом скилле
/configure:dead-code
Check and configure dead code detection tools.
When to Use This Skill
| Use this skill when... | Use another approach when... |
|---|---|
| Setting up dead code detection for a new project | Running a dead code scan and reporting findings (/code:dead-code) |
| Auditing whether Knip, Vulture, or cargo-machete is configured correctly | Manually removing specific unused exports or imports |
| Migrating between dead code detection tools | Debugging why a specific file is flagged as unused |
| Adding dead code checks to CI/CD pipelines | Reviewing dead code findings one by one |
| Standardizing dead code detection across a monorepo | Configuring linting rules (/configure:linting instead) |
Context
- Project root: !
pwd - Package files: !
find . -maxdepth 1 \( -name 'package.json' -o -name 'pyproject.toml' -o -name 'Cargo.toml' \) - Knip config: !
find . -maxdepth 1 \( -name 'knip.json' -o -name 'knip.config.*' \) - Vulture config: !
find . -maxdepth 1 \( -name '.vulture' -o -name 'vulture.ini' \) - Pre-commit: !
find . -maxdepth 1 -name '.pre-commit-config.yaml' - Project standards: !
find . -maxdepth 1 -name '.project-standards.yaml'
Parameters
Parse from command arguments:
--check-only: Report compliance status without modifications (CI/CD mode)--fix: Apply fixes automatically without prompting--tool <knip|vulture|deadcode|machete>: Override tool detection
Dead code detection tools:
- JavaScript/TypeScript: Knip (finds unused files, exports, dependencies)
- Python: Vulture or deadcode (finds unused code)
- Rust: cargo-machete (finds unused dependencies)
Execution
Execute this dead code detection compliance check:
Step 1: Detect project language and existing tools
Check for language and tool indicators:
| Indicator | Language | Tool |
|---|---|---|
knip.json or knip.config.* |
JavaScript/TypeScript | Knip |
package.json with knip |
JavaScript/TypeScript | Knip |
pyproject.toml [tool.vulture] |
Python | Vulture |
.vulture or vulture.ini |
Python | Vulture |
Cargo.toml |
Rust | cargo-machete |
Use WebSearch or WebFetch to verify latest versions before configuring.
Step 2: Analyze current configuration
For the detected tool, check configuration completeness:
Knip:
- Config file exists (
knip.jsonorknip.config.*) - Entry points configured
- Ignore patterns set
- Plugin configurations
- Workspace support (monorepo)
- CI integration
Vulture:
- Configuration file exists
- Minimum confidence set
- Paths configured
- Ignore patterns
- Allowlist file (if needed)
cargo-machete:
- Installed as cargo subcommand
- Workspace configuration
- CI integration
Step 3: Generate compliance report
Print a formatted compliance report:
Dead Code Detection Compliance Report
======================================
Project: [name]
Language: [TypeScript | Python | Rust]
Tool: [Knip 5.x | Vulture 2.x | cargo-machete 0.6.x]
Configuration:
Config file knip.json [EXISTS | MISSING]
Entry points configured [CONFIGURED | AUTO-DETECTED]
Ignore patterns node_modules, dist [CONFIGURED | INCOMPLETE]
Plugin support enabled [ENABLED | N/A]
Detection Scope:
Unused files enabled [ENABLED | DISABLED]
Unused exports enabled [ENABLED | DISABLED]
Unused dependencies enabled [ENABLED | DISABLED]
Unused types enabled [ENABLED | DISABLED]
Scripts:
dead-code command package.json scripts [CONFIGURED | MISSING]
Integration:
Pre-commit hook .pre-commit-config.yaml [OPTIONAL | MISSING]
CI/CD check .github/workflows/ [CONFIGURED | MISSING]
Overall: [X issues found]
If --check-only, stop here.
Step 4: Configure dead code detection (if --fix or user confirms)
Apply configuration based on detected language. Use templates from REFERENCE.md:
- Install tool (e.g.,
bun add --dev knip,uv add --group dev vulture) - Create config file with entry points, exclusions, and plugins
- Add scripts to package.json or create run commands
- Add CI workflow step (warning mode, not blocking)
Step 5: Update standards tracking
Update .project-standards.yaml:
standards_version: "2025.1"
last_configured: "[timestamp]"
components:
dead_code: "2025.1"
dead_code_tool: "[knip|vulture|deadcode|machete]"
dead_code_ci: true
Step 6: Print final report
Print a summary of changes applied, run an initial scan if possible, and provide next steps for reviewing findings.
For detailed configuration templates and usage examples, see REFERENCE.md.
Agentic
Установить configure-dead-code в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
GlobGrepReadWriteEditBash(find *)Bash(bun add *)Bash(npm install *)Bash(uv add *)Bash(npx knip *)Bash(npm run knip *)Bash(vulture *)Bash(uv run vulture *)Bash(uv run deadcode *)Bash(cargo machete *)AskUserQuestionTodoWriteWebSearchWebFetchВложенные файлы
FAQ
Что делает скилл configure-dead-code?
Install and configure dead-code tooling (Knip, Vulture, cargo-machete, deadcode): config, pre-commit, CI. Use when setting up or migrating unused-code scanning; to run a scan use code-dead-code.
Как установить скилл configure-dead-code?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл configure-dead-code запускает скрипты?
Нет, скилл состоит только из инструкций (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