summaryrefslogtreecommitdiff
path: root/Tools/Scripts/webkitpy/tool/steps/commit.py
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@digia.com>2013-09-13 12:51:20 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-09-19 20:50:05 +0200
commitd441d6f39bb846989d95bcf5caf387b42414718d (patch)
treee367e64a75991c554930278175d403c072de6bb8 /Tools/Scripts/webkitpy/tool/steps/commit.py
parent0060b2994c07842f4c59de64b5e3e430525c4b90 (diff)
downloadqtwebkit-d441d6f39bb846989d95bcf5caf387b42414718d.tar.gz
Import Qt5x2 branch of QtWebkit for Qt 5.2
Importing a new snapshot of webkit. Change-Id: I2d01ad12cdc8af8cb015387641120a9d7ea5f10c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
Diffstat (limited to 'Tools/Scripts/webkitpy/tool/steps/commit.py')
-rw-r--r--Tools/Scripts/webkitpy/tool/steps/commit.py16
1 files changed, 6 insertions, 10 deletions
diff --git a/Tools/Scripts/webkitpy/tool/steps/commit.py b/Tools/Scripts/webkitpy/tool/steps/commit.py
index 2bffa4c2a..1d5109a00 100644
--- a/Tools/Scripts/webkitpy/tool/steps/commit.py
+++ b/Tools/Scripts/webkitpy/tool/steps/commit.py
@@ -40,20 +40,17 @@ _log = logging.getLogger(__name__)
class Commit(AbstractStep):
- # FIXME: This option exists only to make sure we don't break scripts which include --ignore-builders
- # You can safely delete this option any time after 11/01/11.
@classmethod
def options(cls):
return AbstractStep.options() + [
- Options.check_builders,
Options.non_interactive,
]
def _commit_warning(self, error):
- working_directory_message = "" if error.working_directory_is_clean else " and working copy changes"
- return ('There are %s local commits%s. Everything will be committed as a single commit. '
+ return ('There are %s local commits (and possibly changes in the working directory. '
+ 'Everything will be committed as a single commit. '
'To avoid this prompt, set "git config webkit-patch.commit-should-always-squash true".' % (
- error.num_local_commits, working_directory_message))
+ error.num_local_commits))
def _check_test_expectations(self, changed_files):
test_expectations_files = [filename for filename in changed_files if filename.endswith('TestExpectations')]
@@ -63,7 +60,7 @@ class Commit(AbstractStep):
args = ["--diff-files"]
args.extend(test_expectations_files)
try:
- self._tool.executive.run_and_throw_if_fail(self._tool.port().check_webkit_style_command() + args, cwd=self._tool.scm().checkout_root)
+ self._tool.executive.run_and_throw_if_fail(self._tool.deprecated_port().check_webkit_style_command() + args, cwd=self._tool.scm().checkout_root)
except ScriptError, e:
if self._options.non_interactive:
raise
@@ -76,12 +73,11 @@ class Commit(AbstractStep):
raise Exception("Attempted to commit with a commit message shorter than 10 characters. Either your patch is missing a ChangeLog or webkit-patch may have a bug.")
self._check_test_expectations(self._changed_files(state))
-
self._state = state
username = None
password = None
- force_squash = False
+ force_squash = self._options.non_interactive
num_tries = 0
while num_tries < 3:
@@ -95,7 +91,7 @@ class Commit(AbstractStep):
self._state["commit_text"] = commit_text
break;
except AmbiguousCommitError, e:
- if self._options.non_interactive or self._tool.user.confirm(self._commit_warning(e)):
+ if self._tool.user.confirm(self._commit_warning(e)):
force_squash = True
else:
# This will correctly interrupt the rest of the commit process.