Discontinue support for draft workflow
As of gerrit 2.15 and later, draft workflow is replaced with work-in-progress and private workflow. See this CL: [1] and this issue upstream: [2]. Even though support for draft worklfow was removed, the drafts magic draft option was preserved, and is mapped to creation of the private change when pushed first time, or creation of change edit on subsequent pushes. These behaviour was alaways controvesial, but was kept in place because 2 major Gerrit clients: repo and git-review were still referencing drafts magic branch. In upcoming gerrit releases the support for drafts magic branch option is discontinued, and thus removed from both repo and git-review: [3]. [1] https://gerrit-review.googlesource.com/c/gerrit/+/97230 [2] https://crbug.com/gerrit/6880 [3] https://gerrit-review.googlesource.com/c/gerrit/+/238898 Sem-Ver: api-break Change-Id: I08a590d42e1ebaa230da960cd192c0b1df528332
This commit is contained in:
parent
5afa906ef5
commit
02491ca845
@ -101,7 +101,5 @@ The name of the script is $action-review where action can be:
|
|||||||
|
|
||||||
* post - run at the end after the review was sent.
|
* post - run at the end after the review was sent.
|
||||||
|
|
||||||
* draft - run when in draft mode.
|
|
||||||
|
|
||||||
If the script returns with an exit status different than zero, git-review will
|
If the script returns with an exit status different than zero, git-review will
|
||||||
exit with the custom shell exit code ``71``.
|
exit with the custom shell exit code ``71``.
|
||||||
|
@ -161,8 +161,6 @@ Indicate that you do, in fact, understand if you are submitting more than
|
|||||||
one patch.
|
one patch.
|
||||||
.It Fl v , Fl \-verbose
|
.It Fl v , Fl \-verbose
|
||||||
Turns on more verbose output.
|
Turns on more verbose output.
|
||||||
.It Fl D , Fl \-draft
|
|
||||||
Submit review as a draft. Requires Gerrit 2.3 or newer.
|
|
||||||
.It Fl R , Fl \-no\-rebase
|
.It Fl R , Fl \-no\-rebase
|
||||||
Do not automatically perform a rebase before submitting the change to
|
Do not automatically perform a rebase before submitting the change to
|
||||||
Gerrit.
|
Gerrit.
|
||||||
@ -178,7 +176,7 @@ Enable or disable a color output. Default is "auto".
|
|||||||
Same thing as \-\-color=never.
|
Same thing as \-\-color=never.
|
||||||
.It Fl \-no\-custom\-script
|
.It Fl \-no\-custom\-script
|
||||||
Do not run scripts, installed as hooks/{action}-review, where action
|
Do not run scripts, installed as hooks/{action}-review, where action
|
||||||
is one of "pre", "draft", or "post".
|
is one of "pre" or "post".
|
||||||
.It Fl \-track
|
.It Fl \-track
|
||||||
Choose the branch to submit the change against (and, if
|
Choose the branch to submit the change against (and, if
|
||||||
rebasing, to rebase against) from the branch being tracked
|
rebasing, to rebase against) from the branch being tracked
|
||||||
|
@ -1423,8 +1423,6 @@ review.
|
|||||||
|
|
||||||
parser.add_argument("--reviewers", nargs="+",
|
parser.add_argument("--reviewers", nargs="+",
|
||||||
help="Add reviewers to uploaded patch sets.")
|
help="Add reviewers to uploaded patch sets.")
|
||||||
parser.add_argument("-D", "--draft", dest="draft", action="store_true",
|
|
||||||
help="Submit review as a draft")
|
|
||||||
parser.add_argument("-n", "--dry-run", dest="dry", action="store_true",
|
parser.add_argument("-n", "--dry-run", dest="dry", action="store_true",
|
||||||
help="Don't actually submit the branch for review")
|
help="Don't actually submit the branch for review")
|
||||||
parser.add_argument("-i", "--new-changeid", dest="regenerate",
|
parser.add_argument("-i", "--new-changeid", dest="regenerate",
|
||||||
@ -1553,7 +1551,6 @@ review.
|
|||||||
parser.add_argument("branch", nargs="?")
|
parser.add_argument("branch", nargs="?")
|
||||||
|
|
||||||
parser.set_defaults(dry=False,
|
parser.set_defaults(dry=False,
|
||||||
draft=False,
|
|
||||||
verbose=False,
|
verbose=False,
|
||||||
update=False,
|
update=False,
|
||||||
setup=False,
|
setup=False,
|
||||||
@ -1661,11 +1658,6 @@ review.
|
|||||||
|
|
||||||
ref = "for"
|
ref = "for"
|
||||||
|
|
||||||
if options.draft:
|
|
||||||
ref = "drafts"
|
|
||||||
if options.custom_script:
|
|
||||||
run_custom_script("draft")
|
|
||||||
|
|
||||||
cmd = ("git push --no-follow-tags %s HEAD:refs/%s/%s" %
|
cmd = ("git push --no-follow-tags %s HEAD:refs/%s/%s" %
|
||||||
(remote, ref, branch))
|
(remote, ref, branch))
|
||||||
push_options = []
|
push_options = []
|
||||||
|
Loading…
Reference in New Issue
Block a user