code-cleanup

Audit codebases and apply high-confidence hygiene fixes across eight parallel review lanes.

12|2|Updated Jun 8, 2026
One-click install
npx skills add https://github.com/Loringtonian/second-brain-template --skill code-cleanup-loringtonian
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: code-cleanup
Source: https://github.com/Loringtonian/second-brain-template/tree/main/.claude/skills/code-cleanup
Command: npx skills add https://github.com/Loringtonian/second-brain-template --skill code-cleanup-loringtonian

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps teams quickly improve a codebase by finding and applying high-confidence hygiene fixes across several maintenance dimensions at once.

Core Features & Use Cases

  • Parallel Code Hygiene Review: Audits duplicate logic, weak types, dead code, circular dependencies, defensive error handling, legacy fallback paths, and low-value comments.
  • Safe High-Confidence Editing: Applies only changes that are clearly justified, while surfacing ambiguous findings for human review.
  • Verify and Repair Loop: Re-runs the target's checks after cleanup and compares them against the pre-change baseline to catch regressions.
  • Use Case: Run it on an aging repository before a release to reduce complexity, tighten types, and remove stale implementation clutter without rewriting the architecture.

Quick Start

Use the code-cleanup skill on this repository to audit the codebase, apply safe cleanup improvements, and verify that the result still passes its checks.

Frequently Asked Questions about code-cleanup

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

FAQPage Schema
How do I safely clean up dead code and remove redundant logic in a large codebase?

To safely remove dead code, this Skill audits repositories across multiple maintenance dimensions in parallel, applying only high-confidence hygiene fixes while surfacing ambiguous findings for human review.

What is the best way to resolve circular dependencies and consolidate weak types before a release?

Resolving circular dependencies and consolidating weak types is handled by running parallel static analysis audits across the codebase, applying safe edits to tighten types and prune legacy fallbacks without rewriting the architecture.

How do I verify that code cleanup changes do not break existing checks or introduce regressions?

To verify code cleanup changes, this Skill uses a verify-and-repair pass that re-runs the target's checks after editing and compares post-change results against a pre-cleanup baseline to automatically catch regressions.

Can I use this code refactoring tool to remove defensive try/catch blocks and legacy fallback paths?

Yes, this code refactoring tool specifically targets defensive try/catch removal and legacy fallback pruning alongside dead-code removal, applying safe high-confidence edits to reduce implementation clutter.

Does this static analysis cleanup tool require any specific dependencies or environment setup?

No specific dependencies are required to run this static analysis cleanup tool, but you must provide a valid target repository path for the parallel audits and subsequent verify-and-repair loop to function.

What are the limitations of applying automated code hygiene fixes across a repository?

The limitation of this automated code hygiene approach is that it only applies clearly justified changes to reduce complexity, meaning ambiguous findings are left untouched and surfaced for manual human review rather than auto-fixed.