AgentSkillsCN

refactor-safe

安全的重构工作流程(小步推进、充分测试、精准诊断)。

SKILL.md
--- frontmatter
name: refactor-safe
description: Safe refactoring workflow (small steps, tests, diagnostics)

Safe Refactor

  1. Add/confirm tests (golden tests if needed).
  2. Make one mechanical change at a time.
  3. Run typecheck + tests after each step.
  4. Avoid large cross-cutting rewrites.