AgentSkillsCN

refactor-pass

在近期改动之后,专注于简洁性的重构工作。当用户要求进行重构或清理、简化代码,或移除无用代码,并期望通过构建与测试来验证行为时使用。

SKILL.md
--- frontmatter
name: refactor-pass
description: Perform a refactor pass focused on simplicity after recent changes. Use when the user asks for a refactor/cleanup pass, simplification, or dead-code removal and expects build/tests to verify behavior.

Refactor Pass

Workflow

  1. Review the changes just made and identify simplification opportunities.
  2. Apply refactors to:
    • Remove dead code and dead paths.
    • Straighten logic flows.
    • Remove excessive parameters.
    • Remove premature optimization.
  3. Run build/tests to verify behavior.
  4. Identify optional abstractions or reusable patterns; only suggest them if they clearly improve clarity and keep suggestions brief.