What problem does it solve?
This Skill ensures large-scale code refactoring is performed safely and with behavior preservation, eliminating the risks of breaking functionality during extensive code changes.
Core Features & Use Cases
- Large-Scale Refactoring: Handle complex refactoring tasks such as renaming symbols, extracting modules, and migrating APIs.
- Behavior Preservation: Enforce that refactors do not alter external behavior, ensuring stability.
- Pre-flight Checks: Before starting a refactor, verify that the working tree is clean, tests pass, and type-checks are successful.
- Atomic Commits: Each refactor step is committed atomically, allowing for individual rollbacks if needed.
- Use Case: Ideal for a team working on a significant codebase, ensuring that refactorings like API changes or structural adjustments do not introduce regressions.
Quick Start
Initiate a refactor with the command '/ck:refactor'. Follow the outlined steps in the documentation for scope definition, dry-run discovery, batching, execution, and verification.