Refactor: $ARGUMENTS

SkillAI & models

Lets your agent restructure code safely in small steps without changing how it behaves.

Instructions available. Your AI can read the instructions. Execution depends on the setup they require.

Add ahel to your AI once: Claude, ChatGPT, Cursor, Claude Code or Codex. Then ask it to use this.

Then ask your AI: use the Refactor: $ARGUMENTS skill

About this skill

Safe refactoring in small steps without changing behavior. Use when asked to refactor, simplify, split a module, remove duplication, or clean up code.

What this skill tells your AI

The instructions your AI receives, as published by justxor/claude-code-pro-course in starter-kit/.claude/skills/refactor/SKILL.md and read by ahel’s review.

Правило №1: поведение не меняется.

  1. Убедись, что тесты для затрагиваемого кода есть и зелёные. Если тестов нет — сначала напиши характеризационные тесты на текущее поведение и закоммить их.
  2. Опиши план: список маленьких шагов (переименование, выделение функции, перенос и т.д.). Каждый шаг оставляет проект рабочим.
  3. Выполняй шаги по одному. После каждого:
    • запусти тесты и проверку типов;
    • если красное — откати шаг и попробуй иначе.
  4. Не смешивай рефакторинг с новыми фичами и исправлениями багов. Найденные баги — запиши в отчёт.
  5. Итог: что изменилось, метрики (строк/функций до и после), найденные баги, что стоит сделать дальше.

Signals

GitHub stars
143
Forks
26
Last commit
Oct 2026
Hacker News mentions
20
Advanced
Item type
skill
Key
refactor-justxor
Source
github.com/justxor/claude-code-pro-course