From 4117b23614cb4245f2366fb6e83c589b15dd8c87 Mon Sep 17 00:00:00 2001 From: Vinta Chen Date: Thu, 8 Jan 2026 15:32:52 +0800 Subject: [PATCH] docs: improve PR review workflow command MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Simplify gh pr list query using --search flag to filter by label, reorganize rejection criteria with merge conflicts first, and streamline output format instructions. 🤖 Generated with Claude Code (https://claude.ai/code) Co-Authored-By: Claude --- .claude/commands/review-pending-prs.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.claude/commands/review-pending-prs.md b/.claude/commands/review-pending-prs.md index e66527b5..5aae5630 100644 --- a/.claude/commands/review-pending-prs.md +++ b/.claude/commands/review-pending-prs.md @@ -10,7 +10,7 @@ Review pending PRs against [CONTRIBUTING.md](../../CONTRIBUTING.md) acceptance c ## Instructions -1. Fetch open PRs (skip reviewed): `gh pr list --repo vinta/awesome-python --limit 20 --json number,title,author,url,labels --jq '[.[] | select(.labels | map(.name) | index("claude reviewed") | not)] | .[:10]'` +1. Fetch 10 open PRs (skip reviewed): `gh pr list --repo vinta/awesome-python --limit 10 --search "-label:\"claude reviewed\"" --json number,title,author,url` 2. For each PR: - Fetch PR details: `gh pr view --repo vinta/awesome-python --json title,body,author,files,url,mergeable,mergeStateStatus` - Fetch PR diff: `gh pr diff --repo vinta/awesome-python` @@ -24,27 +24,27 @@ Would you like me to: 1. Close the rejected PRs with comments? 2. Add "claude reviewed" label to the approved PRs? -3. Add comments to PRs need to be fixed? +3. Do all ``` ## Quick Rejection Checks Check these rules first - if any fail, recommend rejection: +- PR has merge conflicts - Add more than one project per PR - Duplicate of existing entry - Placed under an inappropriate category - Project is archived or abandoned (no commits in 12+ months) - No documentation or unclear use case - Less than 100 GitHub stars AND not justified as a hidden gem -- PR has merge conflicts (notify author to resolve) ## Output Format Provide a simple review: -1. **Rejection Check** - table with the 3 rules and PASS/FAIL -2. **Recommendation** - APPROVE for further review, or REJECT with reason +1. **Rejection Check** - table with the above rules and PASS/FAIL +2. **Recommendation** - APPROVE or REJECT ## Closing PRs