diff options
Diffstat (limited to 'subcmds/upload.py')
-rw-r--r-- | subcmds/upload.py | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/subcmds/upload.py b/subcmds/upload.py index a6ada337..219c5093 100644 --- a/subcmds/upload.py +++ b/subcmds/upload.py | |||
@@ -312,23 +312,23 @@ Gerrit Code Review: http://code.google.com/p/gerrit/ | |||
312 | 312 | ||
313 | # Check if there are local changes that may have been forgotten | 313 | # Check if there are local changes that may have been forgotten |
314 | if branch.project.HasChanges(): | 314 | if branch.project.HasChanges(): |
315 | key = 'review.%s.autoupload' % branch.project.remote.review | 315 | key = 'review.%s.autoupload' % branch.project.remote.review |
316 | answer = branch.project.config.GetBoolean(key) | 316 | answer = branch.project.config.GetBoolean(key) |
317 | 317 | ||
318 | # if they want to auto upload, let's not ask because it could be automated | 318 | # if they want to auto upload, let's not ask because it could be automated |
319 | if answer is None: | 319 | if answer is None: |
320 | sys.stdout.write('Uncommitted changes in ' + branch.project.name + ' (did you forget to amend?). Continue uploading? (y/N) ') | 320 | sys.stdout.write('Uncommitted changes in ' + branch.project.name + ' (did you forget to amend?). Continue uploading? (y/N) ') |
321 | a = sys.stdin.readline().strip().lower() | 321 | a = sys.stdin.readline().strip().lower() |
322 | if a not in ('y', 'yes', 't', 'true', 'on'): | 322 | if a not in ('y', 'yes', 't', 'true', 'on'): |
323 | print("skipping upload", file=sys.stderr) | 323 | print("skipping upload", file=sys.stderr) |
324 | branch.uploaded = False | 324 | branch.uploaded = False |
325 | branch.error = 'User aborted' | 325 | branch.error = 'User aborted' |
326 | continue | 326 | continue |
327 | 327 | ||
328 | # Check if topic branches should be sent to the server during upload | 328 | # Check if topic branches should be sent to the server during upload |
329 | if opt.auto_topic is not True: | 329 | if opt.auto_topic is not True: |
330 | key = 'review.%s.uploadtopic' % branch.project.remote.review | 330 | key = 'review.%s.uploadtopic' % branch.project.remote.review |
331 | opt.auto_topic = branch.project.config.GetBoolean(key) | 331 | opt.auto_topic = branch.project.config.GetBoolean(key) |
332 | 332 | ||
333 | branch.UploadForReview(people, auto_topic=opt.auto_topic, draft=opt.draft) | 333 | branch.UploadForReview(people, auto_topic=opt.auto_topic, draft=opt.draft) |
334 | branch.uploaded = True | 334 | branch.uploaded = True |
@@ -355,11 +355,11 @@ Gerrit Code Review: http://code.google.com/p/gerrit/ | |||
355 | print() | 355 | print() |
356 | 356 | ||
357 | for branch in todo: | 357 | for branch in todo: |
358 | if branch.uploaded: | 358 | if branch.uploaded: |
359 | print('[OK ] %-15s %s' % ( | 359 | print('[OK ] %-15s %s' % ( |
360 | branch.project.relpath + '/', | 360 | branch.project.relpath + '/', |
361 | branch.name), | 361 | branch.name), |
362 | file=sys.stderr) | 362 | file=sys.stderr) |
363 | 363 | ||
364 | if have_errors: | 364 | if have_errors: |
365 | sys.exit(1) | 365 | sys.exit(1) |