SKILL.md
prr - Pull Request Review Tool
Overview
prr brings mailing-list style code reviews to GitHub PRs. Write reviews in your editor, submit directly to GitHub.
Basic Commands
Get a PR for review
prr get owner/repo/PR_NUMBER
# Example
prr get takumi12311123/dotfiles/123
Edit an existing review
prr edit owner/repo/PR_NUMBER
Submit the review
prr submit owner/repo/PR_NUMBER
Check review status
prr status
Remove a review
prr remove owner/repo/PR_NUMBER
Writing Reviews
Basic Structure
After prr get, a .prr file opens in your editor. Lines starting with > are the diff. Write comments between them.
> diff --git a/src/main.rs b/src/main.rs
> @@ -1,5 +1,6 @@
> +fn hello() {
Add your comment here
> + println!("Hello");
> +}
Review Type Directives
Add @prr directive at the top of the file:
@prr approve # Approve the PR
@prr reject # Request changes
@prr comment # Comment only (default)
Single Line Comment
> +fn hello() {
Please add documentation for this function
> + println!("Hello");
> +}
Multi-line (Spanned) Comment
Add a blank line to start the comment span:
> +fn hello() {
Comment about this entire function block
> + println!("Hello");
> +}
Suggestion (Code Proposal)
Same format as GitHub's Suggested changes:
> +fn hello() {
+fn greet(name: &str) {
- println!("Hello, {}!", name);
+}
> + println!("Hello");
> +}
Multi-line Suggestion
> +fn process() {
Please refactor this
+fn process() -> Result<(), Error> {
- validate()?;
- execute()?;
- Ok(())
+}
> + validate();
> + execute();
> +}
Suggest Deletion
Use an empty suggestion block:
> +// TODO: remove this
This comment is unnecessary
> +fn main() {
Configuration
~/.config/prr/config.toml:
[prr]
# Token is read from GH_TOKEN environment variable
workdir = "/Users/username/.local/share/prr"
Local Configuration
Add .prr.toml in your repo to use PR number only:
[local]
repository = "owner/repo"
# Instead of owner/repo/123
prr get 123
Workflow
# 1. Get PR (opens editor)
prr get owner/repo/42
# 2. Write review
# - Add @prr approve/reject/comment at top
# - Add comments between diff lines
# - Use suggestion blocks for code proposals
# 3. Save and close editor
# 4. Submit review
prr submit owner/repo/42
# 5. Edit again if needed
prr edit owner/repo/42
prr submit owner/repo/42
Tips
prr statusshows all review statesprr removedeletes unwanted reviews- Suggestions only work on
+lines (added lines) - Blank lines define spanned comment ranges