gitwatch
is a small process that will clone and poll a git repo for changes.
When new changes are detected it will invoke the command you provide it.
You can download binaries for linux/mac from the release page. Or if you have golang installed:
go get github.com/jondlm/gitwatch
See gitwatch -h
for more help info.
gitwatch --repo ssh://[email protected]/foo.git -- echo saw an update