- Loading...
...
git-pr is the top-level command for interacting with pull requests on a source code hosting platform like GitLab or GitHub. The top-level command git-pr doesn't do anything by itself, instead it delegates all functionality to multiple sub-commands. The available sub-commands to git-pr are:
For more information about a sub-command, see its own wiki page.
All sub-commands takes an optional pull request id as their first argument. The pull request is optional because if you create a pull request with git pr create then git-pr remembers the local branch you created the pull request from. This means you don't have to specify the id for subsequent operations such as git pr set or git pr integrate.
| Code Block |
|---|
$ git pr -h
git-pr is used for interacting with pull requests from a command line.
The following sub-commands are available:
- apply -- apply a pull request
Usage: git pr apply [<ID>]
Flags:
-u, --username NAME Username on host
-r, --remote NAME Name of remote, defaults to 'origin'
--no-token Do not use a personal access token (PAT)
--verbose Turn on verbose output
--debug Turn on debugging output
--version Print the version of this tool
- approve -- approve a pull request
Usage: git pr approve [<ID>]
Flags:
-u, --username NAME Username on host
-r, --remote NAME Name of remote, defaults to 'origin'
-m, --message TEXT Message to author as part of approval (e.g. "Looks good!")
--verbose Turn on verbose output
--debug Turn on debugging output
--version Print the version of this tool
- cc -- add one or more labels
Usage: git pr cc <ARG>...
Flags:
--verbose Turn on verbose output
--debug Turn on debugging output
--version Print the version of this tool
- checkout -- checkout a pull request
Usage: git pr checkout [<ID>]
Flags:
-u, --username NAME Username on host
-r, --remote NAME Name of remote, defaults to 'origin'
-b, --branch NAME Create a new branched named NAME
--no-token Do not use a personal access token (PAT)
--verbose Turn on verbose output
--debug Turn on debugging output
--version Print the version of this tool
- close -- close a pull request
Usage: git pr close [<ID>]
Flags:
-u, --username NAME Username on host
-r, --remote NAME Name of remote, defaults to 'origin'
--verbose Turn on verbose output
--debug Turn on debugging output
--version Print the version of this tool
- contributor -- add or remove contributors
Usage: git pr contributor [<ID>]
Flags:
--add USERNAME Consider pull request contributed to by this user
--remove USERNAME Do not consider pull request contributed to by this user
--verbose Turn on verbose output
--debug Turn on debugging output
--version Print the version of this tool
- create -- create a pull request
Usage: git pr create [<ID>]
Flags:
-u, --username NAME Username on host
-r, --remote NAME Name of remote, defaults to 'origin'
-b, --branch NAME Name of target branch, defaults to 'master'
--cc MAILING LISTS Mailing lists to CC for inital RFR e-mail
--backport REV Create a backport pull request for the given revision
--ignore-workspace Ignore local changes in worktree and staging area when creating pull request
--ignore-local-commits Ignore local commits not pushed when creating pull request
--publish Publish the local branch before creating the pull request |
| Code Block |
$ git pr -h git-pr is used for interacting with pull requests from a command line. The following sub-commands are available: - apply -- apply a pull request Usage: git pr apply [<ID>] Flags: -u, --username NAME Username on host -r, --remote NAME Name of remote, defaults to 'origin' --no-token Do not use a personal access token (PAT) --verbose Turn on verbose output --debug Turn on debugging output --versionjcheck Print the version of this tool - approve -- approve aRun pulljcheck request before creating Usage:the git pr approve [<ID>]pull request Flags: -u, --usernamedraft NAME Username on host -r, --remote NAME Create Namea ofpull remote,request defaultsin todraft 'origin'state --verbose Turn on verbose output --debug Turn on debugging output output --version --version Print the version of this tool - checkoutcsr -- require checkoutCSR for athe pull request Usage: git pr checkoutcsr [<ID>] Flags: -u, --username NAME Username on host -r, --remote NAME Name of remote, defaults to 'origin' -b, --branchneeded NAME This pull Namerequest ofneeds targetan branch,approved defaultsCSR tobefore 'master'integration --no-tokenunneeded This pull request does Do not useneed aan personalapproved accessCSR tokenbefore (PAT)integration --verbose Turn on verbose output --debug Turn on debugging output --version version Print the version of this tool - closefetch -- closefetch a pull request Usage: git pr closefetch [<ID>] Flags: -u, --username NAME Username on host -r, --remote NAME Name of remote, defaults to 'origin' --verbose Turn on verbose output -r, --debugremote NAME Name of remote, defaults Turn on debugging outputto 'origin' --versionno-token Do Printnot use thea versionpersonal ofaccess thistoken tool - create(PAT) --verbose create a pull request Usage: gitTurn pron createverbose [<ID>]output Flags: -u, --usernamedebug NAME Turn Usernameon ondebugging hostoutput -r, --remoteversion NAME Print the version of this tool - info -- show Namestatus of remote, defaults to 'origin'a pull request Usage: git pr info [<ID>] Flags: -bu, --branchusername NAME Username on host -r, --remote NAME Name of target branchremote, defaults to 'masterorigin' --no-cc MAILINGdecoration LISTS Hide any decorations when Mailing lists to CC for inital RFR e-maillisting PRs --ignore-workspace no-token Ignore local changes in worktreeDo andnot staginguse areaa whenpersonal creatingaccess pulltoken request(PAT) --ignore-local-commitschecks Ignore local commits not pushed whenShow creatinginformation pullabout requestchecks --publishauthor Publish Show the localauthor branchof before creating the pull request --jchecktitle Run jcheck before creatingShow the title of the pull request --draftassignees Show the assignees of the pull request Create a--reviewers pull request in draft state Show the reviewers of the pull --verboserequest --contributors Show the additional contributors Turnto onthe verbosepull outputrequest --debugissues Show the issues associated with the Turn on debugging outputpull request --versioncommits Show the commits in pull request Print the version of this tool --branch fetch -- fetch a pull request Usage: git pr fetch [<ID>] Flags: Show the target branch for the pull request -u, --usernameurl NAME Username on host -r, --remote NAME Show Namethe ofurl remote,for defaultsthe topull 'origin'request -b, --branch NAMEstatus NameShow ofthe targetstatus branch,for defaultsthe topull 'master'request --no-tokenlabels Do notShow usethe alabels personalfor accessthe tokenpull (PAT)request --verbose Turn on verbose output --debug Turn on debugging output --version Print the version of this tool - infointegrate -- show statusintegrate of a pull request Usage: git pr infointegrate [<ID>] Flags: -u, --username NAME Username on host -r, --remote NAME Name of remote, defaults to 'origin' --no-decorationatomic Hide any decorations when listing PRs Integrate the pull --no-token Do not use a personal access token (PAT)request atomically --checks verbose ShowTurn informationon aboutverbose checksoutput --authordebug ShowTurn theon author of the pull requestdebugging output --titleversion Print Show the titleversion of the pull request --assignees Show the assignees of the pull request this tool - issue -- add, remove or create issues Usage: git pr issue [<ID>] Flags: --add ID --reviewers ShowConsider theissue reviewerssolved ofby thethis pull request --contributorsremove ID Show the additional contributors to the pull request Do not consider issue --issuesas solved by this pull request Show the issues associated with the pull request--priority 1|2|3|4|5 Priority for issue --commitscomponent NAME Component for Showissue the commits in pull request --create --branch Create Show the target branchan issue for thethis pull request --urlverbose Turn on verbose output Show the url for the pull--debug request --status Turn on debugging output Show the status for the pull request --version --labels Print the version of this Show the labels for thetool - list -- list open pull requestrequests Usage: git pr list [<ID>] --verboseFlags: -u, --username NAME Turn on verbose output --debug Turn on debugging output Username on host -r, --versionremote NAME Print the version of this tool - integrate -- integrate a pull request Usage: git pr integrate [<ID>] Flags: Name of -uremote, --usernamedefaults NAMEto 'origin' Username on host -r, --remote NAMEauthors LIST Name of remote, defaults to 'origin' --atomic IntegrateComma theseparated pulllist requestof atomicallyauthors --verboseassignees LIST Turn on verbose output --debug Comma Turnseparated onlist debuggingof outputassignees --versionlabels LIST Print the version of this tool - list -- list open pull requests Usage: gitComma prseparated list [<ID>]of labels Flags: -u, --username NAMEissues LIST Comma separated Usernamelist onof hostissues -r, --remote NAME --columns id,title,author,assignees,labels Comma separated list of columns to show --no-decoration Name of remote, defaults to 'origin' Hide any decorations when listing --authorsPRs LIST --no-draft Comma separated list of authors Hide --assigneesall LISTpull requests in draft state --no-token Comma separated list of assignees --labels LIST Do not use a personal access token (PAT) --verbose Comma separated list of labels --issues LIST Turn on verbose output --debug Comma separated list of issues --columns id,title,author,assignees,labels Comma separated list of columns to show Turn --no-decorationon debugging output --version Hide any decorations when listing PRs --no-draft Print the version of this tool - reviewer -- add or remove reviewers Usage: git pr reviewer [<ID>] Flags: --add USERNAME Hide allConsider pull requestsrequest reviewed inby draftthis stateuser --no-token remove USERNAME Do not consider pull request reviewed by this user --verbose Turn on verbose output Do not use--debug a personal access token (PAT) Turn --verboseon debugging output --version Print the version of this tool - set -- set properties of a pull request Usage: Turngit onpr verboseset output[<ID>] Flags: -u, --debugusername NAME Username on host -r, --remote NAME Name of remote, defaults to 'origin' --assignees LIST Comma separated list Turn on debugging outputof assignees --versiontitle MESSAGE The title of the pull request --open Set the pull request's state to open Print the version of this tool - set --closed set properties of a pull request Set the Usage: git pr set [<ID>]pull request's state to closed Flags: -u, --usernamebody NAME Username on host Set -r, --remote NAME Name of remote, defaults to 'origin' the body of the pull request --no-draft --assignees LISTMark the Commapull separatedrequest listas ofnot assigneesdraft --titleverbose MESSAGE The title ofTurn theon pullverbose requestoutput --opendebug Turn on debugging Setoutput the pull request's state to open --version --closed Print the version of this tool - show -- show Seta the pull request's state to closed Usage: git pr show [<ID>] Flags: -u, --bodyusername NAME Username on host -r, --remote NAME Set the bodyName of remote, thedefaults pullto request'origin' --no-drafttoken Do Marknot theuse pulla requestpersonal asaccess nottoken draft(PAT) --verbose Turn on verbose output --debug Turn on debugging output --version Print the version of this tool - showsponsor -- showsponsor a pull request Usage: git pr showsponsor [<ID>] Flags: -u, --username NAME Username on host -r, --remote NAME Name of remote, defaults to 'origin' --no-token Do not use a personal access token (PAT) --verbose Turn on verbose output --debug Turn on debugging output --version Print the version of this tool - sponsorsummary -- sponsoradd a summary to the commit message for the pull request Usage: git pr sponsorsummary [<ID>] Flags: -u, --username NAME Username on host -r, --remoteremove NAME Remove Namean of remote, defaults to 'origin'existing summary --verbose --verbose Turn on verbose output --debug Turn on debugging output --version Print the version of this tool - test -- test a pull request Usage: git pr test [<ID>] Flags: -u, --username NAME Username on host -r, --remote NAME Name of remote, defaults to 'origin' -j, --job NAME Name of a job --approve Approve a test request --verbose Turn on verbose output --debug Turn on debugging output --version Print the version of this tool |
...