Commit eb3af715 authored by Aaron Gable's avatar Aaron Gable Committed by Commit Bot

git-cl: don't prompt after cleaning patchset title

BUG=688099

Change-Id: Ic505ab6553b1a9f1e6ab51377bb6519d805a847e
Reviewed-on: https://chromium-review.googlesource.com/436406Reviewed-by: 's avatarAndrii Shyshkalov <tandrii@chromium.org>
Reviewed-by: 's avatarAndrew Bonventre <andybons@chromium.org>
Commit-Queue: Aaron Gable <agable@chromium.org>
parent 2a6c76ea
......@@ -2784,9 +2784,9 @@ class _GerritChangelistImpl(_ChangelistCodereviewBase):
title = re.sub(r'[^\w ]', '', title)
if not automatic_title:
print('WARNING: Patchset title may only contain alphanumeric chars '
'and spaces. Cleaned up title:\n%s' % title)
if not options.force:
ask_for_data('Press enter to continue, Ctrl+C to abort')
'and spaces. You can edit it in the UI. '
'See https://crbug.com/663787.\n'
'Cleaned up title: %s' % title)
# Per doc, spaces must be converted to underscores, and Gerrit will do the
# reverse on its side.
refspec_opts.append('m=' + title.replace(' ', '_'))
......
......@@ -1393,7 +1393,8 @@ class TestGitCl(TestCase):
title='Dont_put_bad_chars')
self.assertIn(
'WARNING: Patchset title may only contain alphanumeric chars '
'and spaces. Cleaned up title:\nDont put bad chars\n',
'and spaces. You can edit it in the UI. See https://crbug.com/663787.\n'
'Cleaned up title: Dont put bad chars\n',
git_cl.sys.stdout.getvalue())
def test_gerrit_reviewers_cmd_line(self):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment