to-pr
Create a pull request from the current branch.
- License 许可
- MIT
- 最近更新
- 2026-11-12
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- to-pr
- description
- Create a pull request from the current branch.
- argument-hint
- [target, base, title, type, scope, or body]
- disable-model-invocation
- true
02 资源文件 4
- 参考文档CREDITS.md310 B
- 参考文档providers/azure.md1.0 KB
- 参考文档providers/github.md401 B
- 参考文档providers/tea.md531 B
03 SKILL.md 正文
<!-- pidev:to-pr-skill -->
To PR
Create the pull request from the current branch and leave it open for review. Never merge it.
Inspect the repository in a single shell command before choosing what to send:
git remote -v; git branch --show-current; git status --short; git log --oneline -5
User guidance: ${ARGUMENTS:-none}
Use the user's values first, and ask before continuing when the guidance, the remotes, and the diff leave a value open.
Steps
- Select the provider for the target remote and read only its guide:
github.com: providers/github.md.dev.azure.comor*.visualstudio.com: providers/azure.md.- Forgejo/Gitea: providers/tea.md.
- Set the base to the user's value or the remote's default branch, then run
git log --oneline <base>..HEADandgit diff <base>...HEAD. - Write the title as
type(scope): summary, resolving types the same way as/commit. - Write the body with the sections below unless the user supplied one.
- Create the pull request with the provider guide. When
HEADhas no upstream, the guide runs the push and creation in one command so one approval covers both and the PR guard sees the sentinel before either action runs.
Body
The size of the change selects the sections. Choose the first matching size:
- Large: touches more than one subsystem, or changes a public interface.
- Medium: changes more than two files, or 20+ lines of observable behaviour.
- Small: changes more than one file, or any observable behaviour.
- Tiny: none of the above.
Render the sections for the size, in this order:
- tiny:
Summary. - small:
Summary,Changes. - medium:
Summary,Changes,Testing. - large:
Summary,Changes,Validation,Testing.
## Summary
<visual>
## Changes
- <change>
## Validation
- **Before:** <before>
**After:** <after>
## Testing
<command and result>
Summary shows the smallest view that makes the change clear: pseudocode for
logic, a call tree for control flow, a component tree for UI, a file tree for
responsibility, a Mermaid diagram for interaction, or a diff for what changes.
Keep only the parts the reader needs.
Changes lists each change, adding reversibility and impact scope when the change is hard to revert or reaches other consumers.
Testing names the command run and its result. Validation shows captured execution output, or a screenshot for a visual change.
Use the project's domain terms exactly. Read domain-docs.md to locate the glossary.
Output
Report the result as a Markdown table, omitting any row with nothing to report:
| Field | Value |
|---|---|
| Link | <url> |
| Source branch | <source> |
| Target branch | <target> |
| Title | <title> |
| Blockers | failure reason |
04 同仓库更多 Skills
writing-for-agents
Reference for writing documents an agent consumes: skills, AGENTS.md or CLAUDE.md, and docs reached by a pointer. Invoke when creating or editing a skill or an agent instruction file, or when a document's pointer wording, load, or structure is in question. Do not invoke merely because the user mentions writing-for-agents, names a skill, or writes 'skill <word>'.
wizard
Generate an interactive bash wizard for steps only a human can perform. Invoke when the user asks for a script or wizard for manual setup: infrastructure provisioning, credentials or CI secrets, a third-party dashboard, or a one-off migration or cutover. Do not invoke for steps the agent can perform, or merely because the user mentions wizard, names a skill, or writes 'skill <word>'.
wait-what
Stop and re-pitch the last message in plain, simplified language.
to-tickets
Split an agreed specification into reviewable vertical-slice issues with explicit blockers, then publish them after confirmation.
to-spec
Turn the current conversation into a specification and publish it after confirmation.
tdd
Test-driven development. Invoke only when the user asks to build a feature or fix a bug test-first, requests a red-green-refactor loop, or requests integration tests.