MC

muhiminosim/code-refactoring-skill

Developer tools

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る

11 stars 品質 66 トレンド 22MIT

A stable refactoring skill for any AI coding agent. Safe, incremental, behavior-preserving code improvements for any programming language, works with Claude Code, Cursor, Antigravity, Copilot, and...

概要

A stable refactoring skill for . Safe, incremental, behavior-preserving code improvements for any programming language. Works with Claude Code, Cursor, Aider, Continue, GitHub Copilot, OpenAI Assistants, or any LLM that accepts a system prompt. Built on Martin Fowler's refactoring catalog, extended with modern patterns for functional programming, async/await, reactive systems, dependency injection, and architectural patterns (MVVM, MVP, Clean Architecture, Hexagonal, Repository, Use Case). - across 6 families (Bloat, OO Abusers, Change Preventers, Dispensables, Couplers, Architectural Violations) - from the complete Fowler catalog + modern patterns + architectural patterns - — safely migrates toward MVVM, MVP, Clean Architecture, Repository pattern, and more - — TypeScript, Python, Go, Rust, Java, Kotlin, C#, Swift, Ruby, C/C++, SQL, and more - — runs your test suite after each change; reverts immediately on failure - — no bundled changes, every step is independently verifiable - —...

README

以下は原文 README の抜粋です。原文を見る。

Code Refactoring Skill

A stable refactoring skill for any AI coding agent. Safe, incremental, behavior-preserving code improvements for any programming language.

Works with Claude Code, Cursor, Aider, Continue, GitHub Copilot, OpenAI Assistants, or any LLM that accepts a system prompt.

Built on Martin Fowler’s refactoring catalog, extended with modern patterns for functional programming, async/await, reactive systems, dependency injection, and architectural patterns (MVVM, MVP, Clean Architecture, Hexagonal, Repository, Use Case).


What It Does

  • Detects code smells across 6 families (Bloat, OO Abusers, Change Preventers, Dispensables, Couplers, Architectural Violations)
  • Applies 70+ refactoring operations from the complete Fowler catalog + modern patterns + architectural patterns
  • Handles architectural refactoring — safely migrates toward MVVM, MVP, Clean Architecture, Repository pattern, and more
  • Works in any language — TypeScript, Python, Go, Rust, Java, Kotlin, C#, Swift, Ruby, C/C++, SQL, and more
  • Tests gate every step — runs your test suite after each change; reverts immediately on failure
  • One operation at a time — no bundled changes, every step is independently verifiable
  • Safety-first — explicit red lines for public APIs, serialization formats, concurrent code, and architectural layer violations

Installation

Interactive installer

npx code-refactoring-skill

Prompts for:

  1. Scope — Global (home dir, all projects) or Project (current directory)
  2. Agent(s) — pick one, several, or all
# Agent Global install path Project install path
1 Any / Generic ~/.agents/skills/refactor/ —
2 Claude Code ~/.claude/skills/refactor/ —
3 Aider ~/.aider-refactor-skill/ CONVENTIONS.md
4 Gemini CLI ~/.gemini/refactor-prompt.md GEMINI.md
5 Continue ~/.continue/refactor-prompt.md .continuerules
6 Cursor ~/.cursor/rules/refactor.mdc .cursor/rules/refactor.mdc
7 Windsurf ~/.codeium/windsurf/memories/refactor.md .windsurfrules
8 GitHub Copilot ~/.config/github-copilot/refactor-prompt.md .github/copilot-instructions.md
9 Zed ~/.config/zed/refactor-prompt.md .rules
10 Amazon Q ~/.aws/amazonq/rules/refactor.md .amazonq/rules/refactor.md
11 OpenHands — .openhands/microagents/refactor.md
12 Sourcegraph Cody — .cody/context.md
13 OpenAI Assistants ~/.openai-refactor-skill/PROMPT.md —

Manual install (any agent)

Copy PROMPT.md into your agent’s system prompt, custom instructions, or rules file. That’s the complete self-contained skill — no other files needed.

curl -O https://raw.githubusercontent.com/MuhiminOsim/code-refactoring-skill/main/PROMPT.md

For a generic global install:

mkdir -p ~/.agents/skills/refactor
GitHub で README 全文を見る

推奨ツール

別のキーワードを試すか、フィルタを外してください。

インストール

npx skillfish add muhiminosim/code-refactoring-skill
MCP 初心者?mcpskill.org のガイドから始めましょう →