1GH-PR-EDIT(1) GitHub CLI manual GH-PR-EDIT(1)
2
3
4
6 gh-pr-edit - Edit a pull request
7
8
9
11 gh pr edit [<number> | <url> | <branch>] [flags]
12
13
14
16 Edit a pull request.
17
18
19 Without an argument, the pull request that belongs to the current
20 branch is selected.
21
22
23 Editing a pull request's projects requires authorization with the
24 "project" scope. To authorize, run "gh auth refresh -s project".
25
26
27
29 --add-assignee <login>
30 Add assigned users by their login. Use "@me" to assign yourself.
31
32
33 --add-label <name>
34 Add labels by name
35
36
37 --add-project <name>
38 Add the pull request to projects by name
39
40
41 --add-reviewer <login>
42 Add reviewers by their login.
43
44
45 -B, --base <branch>
46 Change the base branch for this pull request
47
48
49 -b, --body <string>
50 Set the new body.
51
52
53 -F, --body-file <file>
54 Read body text from file (use "-" to read from standard input)
55
56
57 -m, --milestone <name>
58 Edit the milestone the pull request belongs to by name
59
60
61 --remove-assignee <login>
62 Remove assigned users by their login. Use "@me" to unassign
63 yourself.
64
65
66 --remove-label <name>
67 Remove labels by name
68
69
70 --remove-project <name>
71 Remove the pull request from projects by name
72
73
74 --remove-reviewer <login>
75 Remove reviewers by their login.
76
77
78 -t, --title <string>
79 Set the new title.
80
81
82
84 -R, --repo <[HOST/]OWNER/REPO>
85 Select another repository using the [HOST/]OWNER/REPO format
86
87
88
90 $ gh pr edit 23 --title "I found a bug" --body "Nothing works"
91 $ gh pr edit 23 --add-label "bug,help wanted" --remove-label "core"
92 $ gh pr edit 23 --add-reviewer monalisa,hubot --remove-reviewer myorg/team-name
93 $ gh pr edit 23 --add-assignee "@me" --remove-assignee monalisa,hubot
94 $ gh pr edit 23 --add-project "Roadmap" --remove-project v1,v2
95 $ gh pr edit 23 --milestone "Version 1"
96
97
98
99
100
102 gh-pr(1)
103
104
105
106 Nov 2023 GH-PR-EDIT(1)