request-refactor-plan by mattpocock/skills
npx skills add https://github.com/mattpocock/skills --skill request-refactor-plan当用户希望创建重构请求时,将调用此技能。您应遵循以下步骤。如果认为某些步骤不必要,可以跳过。
向用户询问他们想要解决的问题的详细描述,以及任何潜在的解决方案想法。
探索代码仓库以验证他们的断言,并了解代码库的当前状态。
询问他们是否考虑过其他选项,并向他们介绍其他选项。
与用户详细讨论实现方案。务必极其详尽和彻底。
敲定实现的确切范围。明确计划更改的内容和不计划更改的内容。
查看代码库,检查该代码区域的测试覆盖率。如果测试覆盖率不足,询问用户的测试计划。
将实现分解为一系列微小提交的计划。记住 Martin Fowler 的建议:"使每个重构步骤尽可能小,以便你始终能看到程序在运行。"
使用重构计划创建一个 GitHub issue。使用以下模板作为 issue 描述:
从开发者角度描述开发者面临的问题。
从开发者角度描述问题的解决方案。
一个详细、冗长的实现计划。用通俗易懂的英语编写计划,将实现分解为尽可能小的提交。每个提交都应使代码库保持在可运行状态。
一份已做出的实现决策列表。可包括:
请勿包含具体的文件路径或代码片段。它们可能很快就会过时。
一份已做出的测试决策列表。包括:
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
描述此次重构范围之外的事项。
关于此次重构的任何补充说明。
周安装量
1.2K
仓库
GitHub 星标数
9.5K
首次出现
2026年2月13日
安装于
opencode1.1K
codex1.1K
gemini-cli1.1K
github-copilot1.1K
kimi-cli1.1K
amp1.1K
This skill will be invoked when the user wants to create a refactor request. You should go through the steps below. You may skip steps if you don't consider them necessary.
Ask the user for a long, detailed description of the problem they want to solve and any potential ideas for solutions.
Explore the repo to verify their assertions and understand the current state of the codebase.
Ask whether they have considered other options, and present other options to them.
Interview the user about the implementation. Be extremely detailed and thorough.
Hammer out the exact scope of the implementation. Work out what you plan to change and what you plan not to change.
Look in the codebase to check for test coverage of this area of the codebase. If there is insufficient test coverage, ask the user what their plans for testing are.
Break the implementation into a plan of tiny commits. Remember Martin Fowler's advice to "make each refactoring step as small as possible, so that you can always see the program working."
Create a GitHub issue with the refactor plan. Use the following template for the issue description:
The problem that the developer is facing, from the developer's perspective.
The solution to the problem, from the developer's perspective.
A LONG, detailed implementation plan. Write the plan in plain English, breaking down the implementation into the tiniest commits possible. Each commit should leave the codebase in a working state.
A list of implementation decisions that were made. This can include:
Do NOT include specific file paths or code snippets. They may end up being outdated very quickly.
A list of testing decisions that were made. Include:
A description of the things that are out of scope for this refactor.
Any further notes about the refactor.
Weekly Installs
1.2K
Repository
GitHub Stars
9.5K
First Seen
Feb 13, 2026
Installed on
opencode1.1K
codex1.1K
gemini-cli1.1K
github-copilot1.1K
kimi-cli1.1K
amp1.1K
99,500 周安装