跳到主要内容
知仓学习社ZHICANG

fetch-pr-comments

Fetch and summarize review feedback and conversation from a GitHub PR (unresolved review threads, review bodies, and PR conversation comments) witho…

不碰外部(只输出文字)无严重或高危命中tobihagemann/turbo

它会碰到什么

扫了多少2 个文本文件,8 KB
它会碰到什么不碰外部(只输出文字)
命中总数0 处
命中统计严重 0 · 高 0 · 中 0 · 低 0

这一栏是扫描器报的事实,不是结论。命中多不等于有毒(安全工具、规则库、示例脚本本来就会包含危险写法),命中少也不等于干净。它和你手上的凭据、文件、网络有什么关系,需要你自己看。

技能内容

Fetch PR Comments

Fetch unresolved review comments, top-level review body comments, and PR conversation comments from a GitHub PR and present them in a readable summary. This is a read-only skill -- it does not evaluate, fix, or reply to any comments.

Step 1: Fetch Comments

Auto-detect owner, repo, and PR number from current branch if not provided. Then run scripts/fetch-pr-data.sh, which handles full pagination (review threads, inner comment pages for long threads, reviews, issue comments) and emits a single merged JSON document:

bash <skill-dir>/scripts/fetch-pr-data.sh <owner> <repo> <pr_number>

Output shape:

{
  "meta":          { "title", "url", "headRefName", "baseRefName" },
  "reviewThreads": [ { "id", "isResolved", "isOutdated", "comments": { "nodes": [ { "author", "body", "path", "line", "originalLine", "diffHunk" } ] } } ],
  "reviews":       [ { "author", "body", "state" } ],
  "issueComments": [ { "author", "body", "createdAt", "url" } ]
}

Filter review threads to unresolved only. Filter reviews to those with a non-empty body, excluding PENDING state (unsubmitted drafts). Filter issue comments to those with a non-empty body.

Step 2: Present Results

Display a summary header followed by comments grouped by file.

Summary header:

  • PR title and link
  • Branch: head -> base
  • Total threads / unresolved threads

Top-level review comments (if any):

Show reviews with non-empty body before the file-grouped threads:

## Review Comments

### @reviewer (CHANGES_REQUESTED)
> Review body text here

### @another-reviewer (COMMENTED)
> Another review body here

Issue comments (if any):

Show PR conversation comments after review comments, ordered by createdAt:

## Issue Comments

### @commenter (2026-04-20)
> Issue comment body here

### @another-commenter (2026-04-21)
> Another issue comment body here

Inline threads grouped by file:

For each file with unresolved threads, show:

## `path/to/file.ts`

### Line 42 (by @reviewer)

<diffHunk from first comment>

> Comment body here

### Line 10 (by @another-reviewer) [outdated]

<diffHunk from first comment>

> First comment body
>
> **@reply-author:** Reply body

Formatting rules:

  • Show top-level review body comments first, grouped under "Review Comments"
  • Show PR conversation comments next, grouped under "Issue Comments", ordered by createdAt
  • Then group threads by file path, in the order they appear
  • Within each file, order threads by line number
  • Show the diffHunk from the first comment in each thread as a fenced diff code block before the comment body. This is the code context the reviewer was looking at.
  • For the line number, use line if available. Fall back to originalLine for outdated comments where line is null.
  • Show all comments in a thread (the first is the original review comment; subsequent ones are replies)
  • Mark outdated threads with [outdated]
  • Use blockquotes for comment bodies
  • For threads with multiple comments, show each comment with its author
  • If there are zero unresolved threads, zero review body comments, and zero issue comments, say so and stop

Then call update_plan to mark this step completed and continue with the next step of the active workflow.

Rules

  • If the user wants to fix or reply to comments, direct them to use $resolve-pr-comments.

想直接用这个技能?

本站把开放许可(MIT / Apache 等)的技能按仓库打包整理到网盘,点一下转存到你自己的网盘,不用一个个从 GitHub 拉。许可未声明的技能只给原始仓库链接,不打包。

它属于哪个仓库

星标★ 403
本站分层T2
该仓技能数153
原文件路径codex/skills/fetch-pr-comments/SKILL.md

同一个仓库里的其他技能

看这个仓库的全部 153 个技能

同名技能的其他版本

有 2 个不同仓库或目录里都有叫 fetch-pr-comments 的技能。它们内容并不相同,别混用:

  • tobihagemann/turbo — Fetch and summarize review feedback and conversation from a GitHub PR (unresolved review t