simple github webhook server.
go get github.com/igor-k/hook
cd $GOPATH/src/github.com/igor-k/hook
go install
configuration is in the following format; you can have multiple repositories.
{
"igor-k/hook": {
"master": "/full/path/to/script.sh",
"dev": "/full/path/to/another/script.sh"
},
"igor-k/repo": {
"master": "/full/path/to/script.sh",
}
}
or just
{
"master": "/full/path/to/script.sh",
"dev": "/full/path/to/another/script.sh"
}
each script gets repo ssh url, branch name, and commit hash as arguments.
hook --help # to see all available options
hook -config /path/to/config.json # start a server using a provided config file