From 841202626532b3269e9707e883cc79c2eec66229 Mon Sep 17 00:00:00 2001 From: Steve Rowe Date: Mon, 23 May 2016 15:44:11 -0400 Subject: [PATCH] Fix current branch detection --- dev-tools/scripts/buildAndPushRelease.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev-tools/scripts/buildAndPushRelease.py b/dev-tools/scripts/buildAndPushRelease.py index 1f4837a5c66..f1a7759c7ae 100644 --- a/dev-tools/scripts/buildAndPushRelease.py +++ b/dev-tools/scripts/buildAndPushRelease.py @@ -61,7 +61,7 @@ def getGitRev(): status = os.popen('git status').read().strip() if 'nothing to commit, working directory clean' not in status: raise RuntimeError('git clone is dirty:\n\n%s' % status) - branch = os.popen('git rev-parse --abbrev-ref HEAD') + branch = os.popen('git rev-parse --abbrev-ref HEAD').read().strip() unpushedCommits = os.popen('git log origin/%s..' % branch).read().strip() if len(unpushedCommits) > 0: raise RuntimeError('There are unpushed commits - "git log origin.." output is:\n\n%s' % unpushedCommits)