スキル一覧に戻る
xingxerx

legacy-refactor

by xingxerx

0🍴 0📅 2026年1月21日
GitHubで見るManusで実行

SKILL.md


name: legacy-refactor description: Specifically designed to guide agents through the process of modernizing old codebases without breaking existing dependencies.

Legacy Refactor Protocol

This skill guides the safe refactoring of "legacy" code (code without tests or difficult to understand code).

The Algorithm

  1. Identify Seams: A place where you can alter behavior without editing the place in question (e.g., via subclassing, interface extraction).
  2. Characterization Tests: Before changing ANY code, write tests that capture the current behavior (bugs and all).
    • Goal: Ensure you don't change behavior unintentionally.
  3. Break Dependencies: Use dependency injection to isolate the code module.
  4. Refactor: Make your changes (clean code, upgrade lib, etc.).
  5. Verify: Run characterization tests.

Strategies

  • Sprout Method: Write new logic in a new method and call it from the old one.
  • Wrap Method: Rename the old method, create a new method with the old name that calls the new logic + the old method.

スコア

総合スコア

60/100

リポジトリの品質指標に基づく評価

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

+10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

3ヶ月以内に更新がある

0/10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

0/5

レビュー

💬

レビュー機能は近日公開予定です