.TH "hub-pr" "1" "18 Jul 2021" "hub version 2.14.2" "hub manual" .nh .ad l .SH "NAME" hub\-pr \- Manage GitHub Pull Requests for the current repository. .SH "SYNOPSIS" .P \fB\fChub pr\fR list [\-s \fISTATE\fP] [\-h \fIHEAD\fP] [\-b \fIBASE\fP] [\-o \fISORT\_KEY\fP [\fB\fC\-^\fR]] [\-f \fIFORMAT\fP] [\-L \fILIMIT\fP] .br \fB\fChub pr\fR checkout \fIPR\-NUMBER\fP [\fIBRANCH\fP] .br \fB\fChub pr\fR show [\-uc] [\-f \fIFORMAT\fP] [\-h \fIHEAD\fP] .br \fB\fChub pr\fR show [\-uc] [\-f \fIFORMAT\fP] \fIPR\-NUMBER\fP .SH "COMMANDS" .PP \fIlist\fP .RS 4 List pull requests in the current repository. .RE .PP \fIcheckout\fP .RS 4 Check out the head of a pull request in a new branch. .sp To update the pull request with new commits, use \fB\fCgit push\fR. .RE .PP \fIshow\fP .RS 4 Open a pull request page in a web browser. When no \fIPR\-NUMBER\fP is specified, \fIHEAD\fP is used to look up open pull requests and defaults to the current branch name. With \fB\fC\-\-format\fR, print information about the pull request instead of opening it. .RE .br .SH "OPTIONS" .PP \-s, \-\-state \fISTATE\fP .RS 4 Filter pull requests by \fISTATE\fP. Supported values are: "open" (default), "closed", "merged", or "all". .RE .PP \-h, \-\-head \fIBRANCH\fP .RS 4 Show pull requests started from the specified head \fIBRANCH\fP. The "OWNER:BRANCH" format must be used for pull requests from forks. .RE .PP \-b, \-\-base \fIBRANCH\fP .RS 4 Show pull requests based off the specified \fIBRANCH\fP. .RE .PP \-f, \-\-format \fIFORMAT\fP .RS 4 Pretty print the list of pull requests using format \fIFORMAT\fP (default: "%pC%>(8)%i%Creset %t% l%n"). See the "PRETTY FORMATS" section of git\-log(1) for some additional details on how placeholders are used in format. The available placeholders are: .sp %I: pull request number .sp %i: pull request number prefixed with "#" .sp %U: the URL of this pull request .sp %S: state ("open" or "closed") .sp %pS: pull request state ("open", "draft", "merged", or "closed") .sp %sC: set color to red or green, depending on state .sp %pC: set color according to pull request state .sp %t: title .sp %l: colored labels .sp %L: raw, comma\-separated labels .sp %b: body .sp %B: base branch .sp %sB: base commit SHA .sp %H: head branch .sp %sH: head commit SHA .sp %sm: merge commit SHA .sp %au: login name of author .sp %as: comma\-separated list of assignees .sp %rs: comma\-separated list of requested reviewers .sp %Mn: milestone number .sp %Mt: milestone title .sp %cD: created date\-only (no time of day) .sp %cr: created date, relative .sp %ct: created date, UNIX timestamp .sp %cI: created date, ISO 8601 format .sp %uD: updated date\-only (no time of day) .sp %ur: updated date, relative .sp %ut: updated date, UNIX timestamp .sp %uI: updated date, ISO 8601 format .sp %mD: merged date\-only (no time of day) .sp %mr: merged date, relative .sp %mt: merged date, UNIX timestamp .sp %mI: merged date, ISO 8601 format .sp %n: newline .sp %%: a literal % .RE .PP \-\-color[=\fIWHEN\fP] .RS 4 Enable colored output even if stdout is not a terminal. \fIWHEN\fP can be one of "always" (default for \fB\fC\-\-color\fR), "never", or "auto" (default). .RE .PP \-o, \-\-sort \fIKEY\fP .RS 4 Sort displayed pull requests by "created" (default), "updated", "popularity", or "long\-running". .RE .PP \-^, \-\-sort\-ascending .RS 4 Sort by ascending dates instead of descending. .RE .PP \-L, \-\-limit \fILIMIT\fP .RS 4 Display only the first \fILIMIT\fP pull requests. .RE .PP \-u, \-\-url .RS 4 Print the pull request URL instead of opening it. .RE .PP \-c, \-\-copy .RS 4 Put the pull request URL to clipboard instead of opening it. .RE .br .SH "SEE ALSO" .P hub\-issue(1), hub\-pull\-request(1), hub(1)