Last Updated: February 25, 2016
·
232
· nicocrm

Update / Build site on git pull

I use Bedrock and Sage for a Wordpress install. I should learn to use capistrano to automate the deployment but in the meantime I simply use git. To automate the process to some extent I created a hook that automatically updates the site's plugins and builds it whenever I do a git pull. To this end create a file .git/hooks/post-merge, make it executable, and with this content:

#!/bin/sh

composer install
cd web/app/themes/site-theme
gulp build