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

Unified Diff: gcl.py

Issue 6694009: refactor presubmit parsing code from git-cl into presubmit (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: backport git-cl fixes from gcl_owners patch Created 9 years, 9 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 | git_cl/git_cl.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gcl.py
diff --git a/gcl.py b/gcl.py
index e0d410c2b21c604603a95a7069b100908139fc63..1f1c2c30789e41abb031fa2d05b55a86f8b2f96e 100755
--- a/gcl.py
+++ b/gcl.py
@@ -1169,16 +1169,19 @@ def DoPresubmitChecks(change_info, committing, may_prompt):
change_info.GetFiles(),
change_info.issue,
change_info.patchset)
- result = presubmit_support.DoPresubmitChecks(change=change,
+ output = presubmit_support.DoPresubmitChecks(change=change,
committing=committing,
verbose=False,
output_stream=sys.stdout,
input_stream=sys.stdin,
default_presubmit=root_presubmit,
may_prompt=may_prompt)
- if not result and may_prompt:
+ if not output.should_continue() and may_prompt:
+ # TODO(dpranke): move into DoPresubmitChecks(), unify cmd line args.
print "\nPresubmit errors, can't continue (use --no_presubmit to bypass)"
- return result
+
+ # TODO(dpranke): Return the output object and make use of it.
+ return output.should_continue()
@no_args
« no previous file with comments | « no previous file | git_cl/git_cl.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698