From 3368e09b69057abfbe5548c8e29467e181212024 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Wed, 9 Nov 2016 16:02:06 +0000 Subject: Don't fail to build when we're on a merge commit. --- wscript | 2 ++ 1 file changed, 2 insertions(+) (limited to 'wscript') diff --git a/wscript b/wscript index c55395c26..eda44b52e 100644 --- a/wscript +++ b/wscript @@ -560,6 +560,8 @@ def git_revision(): cmd = "LANG= git log --abbrev HEAD^..HEAD ." output = subprocess.Popen(cmd, shell=True, stderr=subprocess.STDOUT, stdout=subprocess.PIPE).communicate()[0].splitlines() + if len(output) == 0: + return None o = output[0].decode('utf-8') return o.replace("commit ", "")[0:10] -- cgit v1.2.3