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

Unified Diff: git_new_branch.py

Issue 253013004: git new-branch displays an explanatory line. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: Print message to stderr Created 6 years, 8 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 | subprocess2.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: git_new_branch.py
diff --git a/git_new_branch.py b/git_new_branch.py
index b021d4c1f4a2c25118265c3bee67b0f4b8e19db8..810aa02e1b6a167c1a5e5af5a60bb6acfaa2d056 100755
--- a/git_new_branch.py
+++ b/git_new_branch.py
@@ -41,12 +41,12 @@ def main(args):
# TODO(iannucci): Detect unclean workdir then stash+pop if we need to
# teleport to a conflicting portion of history?
run('checkout', '--track', opts.upstream, '-b', opts.branch_name)
-
get_or_create_merge_base(opts.branch_name)
except subprocess2.CalledProcessError as cpe:
sys.stdout.write(cpe.stdout)
sys.stderr.write(cpe.stderr)
return 1
+ sys.stderr.write('Switched to branch %s.' % opts.branch_name)
if __name__ == '__main__': # pragma: no cover
« no previous file with comments | « no previous file | subprocess2.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698