Why can't my recipient post run virtualenv source command?

I have a post-receive hook that works as a user of 'git'. I have virtualenv / python / ve // ​​bin / activate which can be read with git. Duration:

source /python/ve/<name>/bin/activate 

works great for the user in the git group.

When it starts as a hook after receiving after clicking, I get the error "source: not found".

I'm not sure where else to look - any hints are greatly appreciated.

+4
source share
1 answer

This is a bit of a hunch since you didn't specify your full post-receive hook, but I suspect you don't have a shebang line by pointing to /bin/bash at the top. Your post-receive hook should start:

 #!/bin/bash 

I suspect this because if I run a Bourne line shell like dash , I get the same error when trying to source nothing with source .

+11
source

All Articles