Add exit function and use it in post-receive script. Fixes Issue #13.