post-receive 395 B

1234567891011121314151617
  1. #!/bin/sh
  2. # The hook is called by Git with 3 arguments: oldrev newrev refname
  3. # Git automatically chdir into the .git folder (for bare repo) or working dir
  4. # (for non-bare repo).
  5. # Ignore gitolite-admin pushes from post-receive hook.
  6. if [ $(basename $(pwd)) = 'gitolite-admin.git' ]; then
  7. exit 0
  8. fi
  9. while read oldrev newrev refname
  10. do
  11. /opt/mcfi/push.py $oldrev $newrev $refname
  12. done