Command Palette

Search for a command to run...

Назад к скиллам
скилл № 79321

Refactor

Use when refactoring code to improve structure, reduce duplication, and apply SRP/DRY principles without changing behavior.

БесплатноБез исполняемых скриптов
whchoi98от whchoi98★ 20 звёзд на GitHub

Установить Refactor в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Об этом скилле

Refactor Skill

Refactor existing code to improve quality without changing behavior.

Principles

  • Improve structure without changing behavior
  • Single Responsibility Principle (SRP)
  • Remove duplicate code (DRY)
  • Small, incremental steps with verification

Process

1. Analysis

  • Identify the target code and its tests
  • Map all callers and dependencies
  • Confirm test coverage exists (suggest adding tests first if not)

2. Plan

Present the refactoring plan to the user:

  • What will change
  • What will NOT change (behavior preservation)
  • Risk assessment (low/medium/high)

3. Execute

  • Make changes in small, verifiable steps
  • Run tests after each step if possible
  • Keep commits atomic

4. Verify

  • Confirm all existing tests pass
  • Verify no behavior changes
  • Check that the refactoring achieved its goal

Usage

Run with /refactor command

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

FAQ

Что делает скилл Refactor?

Use when refactoring code to improve structure, reduce duplication, and apply SRP/DRY principles without changing behavior.

Как установить скилл Refactor?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл Refactor запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить Refactor с