gh pr list

列出并筛选此存储库中的请求

gh pr list [flags]

Options

-a, --assignee <string>
Filter by assignee
-A, --author <string>
Filter by author
-B, --base <string>
Filter by base branch
-d, --draft
Filter by draft state
-H, --head <string>
Filter by head branch
-q, --jq <expression>
jq 表达式,过滤 JSON 输出
--json <fields>
JSON 输出特殊字段
-l, --label <strings>
Filter by labels
-L, --limit <int>
Maximum number of items to fetch
-S, --search <query>
Search pull requests with query
-s, --state <string>
Filter by state: {open|closed|merged|all}
-t, --template <string>
模板化输出
-w, --web
Open the browser to list the pull requests

Options inherited from parent commands

-R, --repo <[HOST/]OWNER/REPO>
使用 [HOST/]OWNER/REPO 格式,选择另一存储库

Examples

# 列出 PRs,作者是你
$ gh pr list --author "@me"

# 列出 PRs,关联你的
$ gh pr list --assignee "@me"

# 列出 PRs ,bug 标签, 多个标签组合
$ gh pr list --label bug --label "priority 1"

# 列出 PRs,使用 search 语法
$ gh pr list --search "status:success review:required"

# 浏览器打开
$ gh pr list --web

See also