Skip to main content

pr-readiness

Run a PR readiness check on the current branch before opening or finalizing a pull request. Optional first argument is a Jira issue ID (e.g. ABC-123). Optional second argument is a base branch name.

跳到安装

来源信息

仓库
woocommerce/woocommerce-paypal-payments
最近来源活动
2026年7月22日 15:05
检测到的 SKILL.md 语言
英语
星标
80
分支
70

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。

正在显示 SKILL.md

SKILL.md
来源说明 · 只读预览
name
pr-readiness
description
Run a PR readiness check on the current branch before opening or finalizing a pull request. Optional first argument is a Jira issue ID (e.g. ABC-123). Optional second argument is a base branch name.
argument-hint
[JIRA-ID] [base-branch]
invocation
user
You dispatch the `pr-readiness` sub-agent to review the current branch. You do NOT perform the review yourself — your job is to gather context and hand it off. ## Argument Parsing Arguments after `/pr-readiness`: - An identifier matching `[A-Z]+-\d+` is a Jira issue ID. - Any other argument is treated as the base branch name. Both are optional. Order does not matter. ## Steps ### 1. Resolve Base Branch If a base branch was passed as an argument, use it. Otherwise, run `git symbolic-ref refs/remotes/origin/HEAD` and strip the `refs/remotes/origin/` prefix. Fall back to `main` if that fails. ### 2. Gather Branch Context Run and capture output from: - `git rev-parse --abbrev-ref HEAD` — current branch - `git diff --stat <base>...HEAD` — file/line summary - `git diff <base>...HEAD` — full diff - `git log <base>..HEAD --oneline` — commit list If the diff is empty, stop and tell the user there is nothing to review. ### 3. Fetch Jira Context Skip this step entirely if no Jira ID was provided. Use the connected Atlassian/Jira MCP to fetch the issue. Capture: key, title, description, issue type. If the fetch fails, mention it in a single line and continue without Jira context — do NOT abort. ### 4. Dispatch Agent Invoke the `pr-readiness` sub-agent via the Task tool. Pass a single structured payload following this template: ````payload-template Branch: {current} → {base} Jira: {key} — {title} {description} [omit the entire Jira block if no issue context was fetched] Diff summary: {git diff --stat output} Commit list: {git log --oneline output} Full diff: {git diff output} ```` ### 5. Return Report Pass the sub-agent's report back to the user verbatim. Do not summarize, rewrite, or comment on it. The developer needs the full report to act on.
在 GitHub 查看