diff options
author | Changcheng Xiao <xchangcheng@google.com> | 2017-08-07 15:05:46 +0200 |
---|---|---|
committer | Changcheng Xiao <xchangcheng@google.com> | 2017-08-07 15:08:18 +0200 |
commit | d88f53e2b9634b9645f80b2d8e653beac24711fe (patch) | |
tree | 7fc6d88e282aa7d11322549f900b6708f135ab3f /subcmds | |
parent | 87984c6db4962043c2b9e5a5a4a30eaf6d066077 (diff) | |
download | git-repo-d88f53e2b9634b9645f80b2d8e653beac24711fe.tar.gz |
Migrate git-repo to create private changes rather than drafts
Considering that some users might expect changes created with
'-d' option are not public. Private changes may be a better
choice here than work-in-progress changes.
Change-Id: I46a8fb9ae38beb41cf96d6abe82bea6db2439669
Diffstat (limited to 'subcmds')
-rw-r--r-- | subcmds/upload.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/subcmds/upload.py b/subcmds/upload.py index 61b18bc2..f40ac9df 100644 --- a/subcmds/upload.py +++ b/subcmds/upload.py | |||
@@ -152,8 +152,8 @@ Gerrit Code Review: http://code.google.com/p/gerrit/ | |||
152 | dest='current_branch', action='store_true', | 152 | dest='current_branch', action='store_true', |
153 | help='Upload current git branch.') | 153 | help='Upload current git branch.') |
154 | p.add_option('-d', '--draft', | 154 | p.add_option('-d', '--draft', |
155 | action='store_true', dest='draft', default=False, | 155 | action='store_true', dest='private', default=False, |
156 | help='If specified, upload as a draft.') | 156 | help='(Deprecated). If specified, upload as a private change.') |
157 | p.add_option('-p', '--private', | 157 | p.add_option('-p', '--private', |
158 | action='store_true', dest='private', default=False, | 158 | action='store_true', dest='private', default=False, |
159 | help='If specified, upload as a private change.') | 159 | help='If specified, upload as a private change.') |
@@ -205,7 +205,7 @@ Gerrit Code Review: http://code.google.com/p/gerrit/ | |||
205 | 205 | ||
206 | destination = opt.dest_branch or project.dest_branch or project.revisionExpr | 206 | destination = opt.dest_branch or project.dest_branch or project.revisionExpr |
207 | print('Upload project %s/ to remote branch %s%s:' % | 207 | print('Upload project %s/ to remote branch %s%s:' % |
208 | (project.relpath, destination, ' (draft)' if opt.draft else '')) | 208 | (project.relpath, destination, ' (private)' if opt.private else '')) |
209 | print(' branch %s (%2d commit%s, %s):' % ( | 209 | print(' branch %s (%2d commit%s, %s):' % ( |
210 | name, | 210 | name, |
211 | len(commit_list), | 211 | len(commit_list), |
@@ -386,7 +386,6 @@ Gerrit Code Review: http://code.google.com/p/gerrit/ | |||
386 | 386 | ||
387 | branch.UploadForReview(people, | 387 | branch.UploadForReview(people, |
388 | auto_topic=opt.auto_topic, | 388 | auto_topic=opt.auto_topic, |
389 | draft=opt.draft, | ||
390 | private=opt.private, | 389 | private=opt.private, |
391 | wip=opt.wip, | 390 | wip=opt.wip, |
392 | dest_branch=destination) | 391 | dest_branch=destination) |