reject-pr

Posts an existing code review as a change-request review on a GitHub pull request.

17.3k|1.6k|Updated Apr 28, 2014
One-click install
npx skills add https://github.com/questdb/questdb --skill reject-pr
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: reject-pr
Source: https://github.com/questdb/questdb/tree/main/.pi/skills/reject-pr
Command: npx skills add https://github.com/questdb/questdb --skill reject-pr

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

After reviewing a pull request, you still need to manually post the review, tag the author, set the PR to "changes requested", and clear the READY label. This Skill automates that entire rejection workflow in one step using the GitHub CLI.

Core Features & Use Cases

  • Review Posting: Takes the most recent review-pr report from the conversation and posts it verbatim as the PR review body, tagging the PR author.
  • Change Request Automation: Sets the PR to the "changes requested" state and removes the READY label if present.
  • Self-Authored PR Fallback: Falls back to a plain PR comment when GitHub blocks requesting changes on your own PR.
  • Use Case: You just finished reviewing a teammate's branch with review-pr and found blocking issues. Run this Skill to publish the review as a formal change request without switching to the GitHub UI.

Quick Start

Reject the pull request for the currently checked-out branch using the review from this conversation.

Frequently Asked Questions about reject-pr

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I request changes on a GitHub pull request from the command line?

Use gh pr review with the --request-changes flag and a --body-file containing the review text. This sets the PR to the changes requested state and posts the review body as the review comment.

How do I remove a label from a GitHub pull request with gh CLI?

Run gh pr edit with the --remove-label flag followed by the label name. Check the label exists first with gh pr view --json labels to avoid errors when the label is absent.

Why can't I request changes on my own GitHub pull request?

GitHub does not allow requesting changes on a self-authored PR. The workaround is to post the review as a regular comment with gh pr comment instead, which still communicates the feedback to reviewers.

Can I reject a pull request without writing a new review?

Yes, this workflow reuses the most recent review report from the conversation and posts it verbatim. If no prior review exists, you must run the review step first rather than fabricating feedback.

How do I auto-detect the PR for the current git branch?

Run gh pr view --json number to resolve the PR associated with the checked-out branch. You can override detection by passing an explicit PR number or URL as an argument.