Updating remote git work trees

04 Nov 2016

Just as a reminder, the way to update a remote git work tree when pushing (in other words, not just update the repo, but change the checked-out work tree as well, in order to do things like updating a live website) is to have the following git config setting on the remote repo (not your local repo).

git config receive.denyCurrentBranch updateInstead

This only works with Git 2.3+, but you should definitely be way past that anyway.