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

Unified Diff: git_cl.py

Issue 549513002: Return 1 from git_cl land when you Ctrl-C it in the middle. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: fix nit 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: git_cl.py
diff --git a/git_cl.py b/git_cl.py
index 65524207863dc006b2375af2c1b72d3829abd39d..fcb003c493f229e598db5f1fe2cc76fc7891b9cc 100755
--- a/git_cl.py
+++ b/git_cl.py
@@ -2037,6 +2037,7 @@ def SendUpstream(parser, args, cmd):
print 'Failed to push. If this persists, please file a bug.'
return 1
+ killed = False
if pushed_to_pending:
try:
revision = WaitForRealCommit(remote, revision, base_branch, branch)
@@ -2044,7 +2045,7 @@ def SendUpstream(parser, args, cmd):
# real ref.
pushed_to_pending = False
except KeyboardInterrupt:
- pass
+ killed = True
if cl.GetIssue():
to_pending = ' to pending queue' if pushed_to_pending else ''
@@ -2081,7 +2082,7 @@ def SendUpstream(parser, args, cmd):
if os.path.isfile(hook):
RunCommand([hook, merge_base], error_ok=True)
- return 0
+ return 1 if killed else 0
def WaitForRealCommit(remote, pushed_commit, local_base_ref, real_ref):
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698