knip-audit

Triage Knip findings and remove dead files or unused dependencies.

1|Updated Feb 20, 2026
One-click install
npx skills add https://github.com/jamesaphoenix/tx-agent-kit --skill knip-audit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: knip-audit
Source: https://github.com/jamesaphoenix/tx-agent-kit/tree/main/.claude/skills/knip-audit
Command: npx skills add https://github.com/jamesaphoenix/tx-agent-kit --skill knip-audit

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Triage Knip findings to improve repository hygiene by removing dead files, unused dependencies, and manifest issues that degrade build reliability and clarity.

Core Features & Use Cases

  • Triage findings: Classify Knip reports by relevance, distinguishing real dead files from intentional or edge-case configurations.
  • Hygiene cleanup: Delete dead files, prune unused dependencies, and fix manifest issues that Knip flags.
  • Guardrails & ignores: Add targeted ignores in .knip.jsonc when findings are intentional or framework-specific, ensuring they don't pollute future runs.
  • Validation: Re-run lint gates (pnpm lint) to confirm changes, and iterate if necessary.
  • Use Case: When a CI scan flags stale dependencies or missing files, apply this skill to clean up and document decisions.

Quick Start

Execute the Knip audit by triaging findings, removing dead files and unused dependencies, and then re-run pnpm lint:knip:strict.

Frequently Asked Questions about knip-audit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I triage Knip findings to remove unused dependencies and dead files?

Triage Knip findings by classifying reports to distinguish real dead files from intentional configurations, then delete dead files, prune unused dependencies, and fix manifest issues to improve repository hygiene.

What is the best way to handle Knip lint errors that are intentional framework configurations?

Add targeted ignores in .knip.jsonc for intentional or framework-specific findings. This documents decisions and ensures valid edge-case configurations do not pollute future pnpm lint:knip runs.

How do I validate repository cleanup changes after removing stale dependencies?

Validate repository cleanup changes by re-running lint gates using pnpm lint:knip. This confirms that removing dead files and unused dependencies did not introduce new hygiene or manifest issues.

Does this Knip audit approach work with pnpm lint for CI pipeline integration?

Yes, the Knip audit integrates with pnpm lint by enforcing checks and rules defined in .knip.jsonc. It validates changes using pnpm lint:knip to ensure CI scans pass without stale dependency errors.

When do I need to run a Knip audit for repository hygiene optimization?

Run a Knip audit when lint reports indicate hygiene issues, manifest errors, or optimization opportunities, or when a CI scan flags stale dependencies and missing files that degrade build reliability.