AGENT SKILL
PR 压缩合并与分支重置
merge
对开放的 PR 执行压缩合并(squash merge),拉取 master 分支,并重置 dev 分支。
- License 许可
- MIT
- 最近更新
- 2026-05-15
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- merge
- description
- Squash-merge the open PR, pull master, and reset dev branch
- allowed-tools
- Bash(git *, gh *)
- disable-model-invocation
- true
02 资源文件 3
- 许可证LICENSE1.0 KB
- 参考文档SOURCE.md351 B
- 参考文档TRUST.auto.yaml2.1 KB
03 SKILL.md 正文
Merge PR and Reset
Instructions
-
Check the current branch with
git branch --show-current. If not ondev, abort. -
Find the open PR for dev → master:
gh pr list --head dev --base master --state open --json number,title,urlIf no open PR exists, abort with an error message.
-
Squash-merge the PR:
gh pr merge NUMBER --squash --delete-branchThis will also delete the remote
devbranch. -
Switch to master and pull:
git checkout master git pull -
Delete the local dev branch if it still exists:
git branch -D dev 2>/dev/null || true -
Report success with the merged PR URL and the new commit on master.
04 同仓库更多 Skills
开发服务器停止
stop
停止正在运行的开发服务器。
★ 1
Git 仓库状态查看
status
显示当前分支、工作区(working tree)状态以及所有未关闭的 PR。
★ 1
开发服务器启动
run
在后台启动开发服务器;如果服务器已在运行,则将其重启。
★ 1
GitHub PR 创建
pr
推送 dev 分支并创建一个到 master 的 GitHub PR(根据提交自动生成标题和正文)。
★ 1
GitHub 草稿 PR 创建
pr-draft
推送 dev 分支并创建一个到 master 的 GitHub 草稿 PR(根据提交自动生成标题和正文)。
★ 1
master 分支检出与更新
master
检出 master 分支并拉取最新更改。
★ 1