Fix the print of the rebase error message, and make the output prettier too.
For some reason .output doesn't throw an AttributeError, but returns None ,
instead. .stdout is the correct attribute.
R=agable@chromium.org
BUG=
Review URL: https://codereview.chromium.org/212493003
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@259695 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/git_common.py b/git_common.py
index 284c18c..80398ba 100644
--- a/git_common.py
+++ b/git_common.py
@@ -432,7 +432,7 @@
except subprocess2.CalledProcessError as cpe:
if abort:
run('rebase', '--abort')
- return RebaseRet(False, cpe.output)
+ return RebaseRet(False, cpe.stdout)
def remove_merge_base(branch):
diff --git a/git_rebase_update.py b/git_rebase_update.py
index 9d353c6..37f3066 100755
--- a/git_rebase_update.py
+++ b/git_rebase_update.py
@@ -137,6 +137,9 @@
else:
# rebase and leave in mid-rebase state.
git.rebase(parent, start_hash, branch)
+ print "Failed!"
+ print
+ print "Here's what git-rebase had to say:"
print squash_ret.message
print
print textwrap.dedent(