Re:Poll: How often do you deploy to production?
by shawabawa3 on Thursday June 27, 2013 @06:28AM
(#5951516)
Strange, it might be to do with GIT_WORK_TREE and GIT_DIR being set (they are set automatically in hooks I think).
My hook is:
cd $REPO_DIR
unset GIT_DIR
unset GIT_WORK_TREE
git checkout deploy && \
git stash && \
git pull
I always found that the hook never really worked for some bizarre reason. Even something as simple as:
cd /home/deployer/wordpress/wp-content/themes/my-theme && git pull origin master
failed.