Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(388)

Unified Diff: gclient_scm.py

Issue 587253005: Use CheckCallAndFilterAndHeader for git commands. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: update test expectations Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/gclient_scm_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gclient_scm.py
diff --git a/gclient_scm.py b/gclient_scm.py
index dff72d09212b96ac2cec421e219f3778e9b5228e..b4ce189c4a3cd6427d2522c3c7c29a9dd98a037a 100644
--- a/gclient_scm.py
+++ b/gclient_scm.py
@@ -1125,16 +1125,16 @@ class GitWrapper(SCMWrapper):
def _Run(self, args, options, show_header=True, **kwargs):
# Disable 'unused options' warning | pylint: disable=W0613
- cwd = kwargs.setdefault('cwd', self.checkout_path)
+ kwargs.setdefault('cwd', self.checkout_path)
kwargs.setdefault('stdout', self.out_fh)
kwargs['filter_fn'] = self.filter
kwargs.setdefault('print_stdout', False)
env = scm.GIT.ApplyEnvVars(kwargs)
cmd = ['git'] + args
if show_header:
- header = "running '%s' in '%s'" % (' '.join(cmd), cwd)
- self.filter(header)
- return gclient_utils.CheckCallAndFilter(cmd, env=env, **kwargs)
+ gclient_utils.CheckCallAndFilterAndHeader(cmd, env=env, **kwargs)
+ else:
+ gclient_utils.CheckCallAndFilter(cmd, env=env, **kwargs)
class SVNWrapper(SCMWrapper):
« no previous file with comments | « no previous file | tests/gclient_scm_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698