If this is your production server, it seems like a bad idea to let someone run arbitrary git commands in this repository. Any merging (e.g. with git pull ) can create conflicts that leave your live server with a broken setting. I think that people usually deal with this problem by allowing developers to deploy to a production server by clicking on an empty repository with a post-receive or update hook that checks:
Of course, this does not stop people from combining not only what happens locally, and then clicking on an intermediate server or a live server, but you are unlikely to be able to do this, I think - people just need to check theirs (locally or on an intermediate server) before than press.
source share