From 5ed2f16480142f0887cc1a6257ff53e2abc3e5b6 Mon Sep 17 00:00:00 2001 From: Andrew C Date: Sat, 23 Jan 2016 10:35:27 -0500 Subject: [PATCH] [devtools] github-merge get toplevel dir without extra whitespace Fixes a bug in github merge when it runs the tests where the toplevel directory has an extra '\n' appended to the path string. Now it doesn't. --- contrib/devtools/github-merge.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/devtools/github-merge.py b/contrib/devtools/github-merge.py index 33d33b700..11118fd7d 100755 --- a/contrib/devtools/github-merge.py +++ b/contrib/devtools/github-merge.py @@ -153,7 +153,7 @@ def main(): # Run test command if configured. if testcmd: # Go up to the repository's root. - toplevel = subprocess.check_output([GIT,'rev-parse','--show-toplevel']) + toplevel = subprocess.check_output([GIT,'rev-parse','--show-toplevel']).strip() os.chdir(toplevel) if subprocess.call(testcmd,shell=True): print("ERROR: Running %s failed." % testcmd,file=stderr)