From: Stefan Beller Date: Thu, 06 Apr 2017 18:48:35 GMT Subject: Re: how-to get commit content with pre-receive hook ? Message-ID: In-Reply-To: >> >> But I don't know how to get the *content* of the file being submitted to run >> my syntax check rules against it ! >> > git log -p .. > git diff .. or in case of the tool requiring a full worktree mkdir /tmp/test GIT_WORKTREE=/tmp/test git checkout -f and then perform the check on that full tree?