cnb-rs pr status
cnb-rs pr status显示当前仓库中与我相关的 PR 状态概览。
参考 gh pr status,分栏展示:
- Current branch — 当前 git 分支关联的 open PR(含 mergeable 状态)
- Created by you — 我创建的 open PR(最多 10 条)
- Requesting a code review from you — 需要我评审的 open PR(最多 10 条)
每栏按 -updated_at(最近更新优先)排序。
示例
bash
# 查看当前仓库 PR 状态
cnb-rs pr status
# 指定仓库
cnb-rs pr status --repo wwvo/cnb-rs/cnb-rs
# JSON 输出
cnb-rs pr status --json输出格式
Relevant pull requests in wwvo/cnb-rs/cnb-rs
Current branch
#42 添加 npm 分发支持 [feature/npm → main] ✓ Mergeable
Created by you
#42 添加 npm 分发支持 [feature/npm → main] ✓ Mergeable 约 2 小时前
#38 重构 auth 模块 [refactor/auth → main] 约 3 天前
Requesting a code review from you
#45 修复 CI 构建问题 [fix/ci → main] × Conflict 约 1 小时前Mergeable 状态标记
| 标记 | 含义 |
|---|---|
✓ Mergeable | 无冲突,可合并 |
× Conflict | 存在合并冲突 |
⋯ Checking | 正在检查中 |
× No merge base | 无共同祖先 |
JSON 输出
json
{
"currentBranch": { ... } | null,
"createdBy": [...],
"needsReview": [...]
}继承的全局选项:
--repo <REPO>: 指定仓库路径(格式:group/repo)--json: 以 JSON 格式输出--domain <DOMAIN>: 指定目标域名(默认:cnb.cool)