aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2015-02-25 22:01:20 +0100
committerRalf Jung <post@ralfj.de>2015-02-25 22:01:20 +0100
commit301520c0234eb50350361fac263bcebd2db139c2 (patch)
tree1fca00c2b388b8a27375b08acb603467f32d4a75
parentd1fcac9c35289f6fac7ad302d41dba33467ceb9d (diff)
compensate for the gitolite mirror script not to be a proper executable
-rw-r--r--git_mirror.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/git_mirror.py b/git_mirror.py
index 16a8896..0fe699e 100644
--- a/git_mirror.py
+++ b/git_mirror.py
@@ -174,7 +174,7 @@ class Repo:
# Now run the post-receive hooks. This will *also* push the changes to all mirrors, as we
# are one of these hooks!
os.putenv("GIT_MIRROR_SOURCE", mirror) # tell ourselves which repo we do *not* have to update
- with subprocess.Popen(['hooks/post-receive'], stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.STDOUT) as p:
+ with subprocess.Popen(['/bin/sh', 'hooks/post-receive'], stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.STDOUT) as p:
(stdout, stderr) = p.communicate("{0} {1} {2}\n".format(oldsha, newsha, ref).encode('utf-8'))
stdout = stdout.decode('utf-8')
if p.returncode: