summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWolfgang Rohdewald <wolfgang@rohdewald.de>2016-08-05 01:42:05 (GMT)
committerWolfgang Rohdewald <wolfgang@rohdewald.de>2016-08-24 10:26:51 (GMT)
commitfdee4a6d00f2ecbe19d01ac7485d7fe251f5f7d3 (patch)
tree99429a12a80559d1a5c6da8e832100278789e20c
parent6c15ac9ae2948805f17bc434d31cccedaddfe92d (diff)
kajonggtest now finds git in /usr/local/bin too
-rwxr-xr-xsrc/kajonggtest.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/kajonggtest.py b/src/kajonggtest.py
index 9fa4d97..0c64c22 100755
--- a/src/kajonggtest.py
+++ b/src/kajonggtest.py
@@ -367,8 +367,10 @@ def onlyExistingCommits(commits):
"""filter out non-existing commits"""
global KNOWNCOMMITS # pylint: disable=global-statement
if len(KNOWNCOMMITS) == 0:
- for branch in subprocess.check_output('git branch'.split(), env={'LANG': 'C'}).split('\n'):
- if not 'detached' in branch and not 'no branch' in branch:
+ env = os.environ.copy()
+ env['LANG'] = 'C'
+ for branch in subprocess.check_output('git branch'.split(), env=env).split('\n'):
+ if 'detached' not in branch and 'no branch' not in branch:
KNOWNCOMMITS |= set(subprocess.check_output(
'git log --max-count=200 --pretty=%h {branch}'.format(
branch=branch[2:]).split()).split('\n'))