Switch branches/tags
Nothing to show
Find file History
Latest commit 74d8c00 Aug 30, 2014
Failed to load latest commit information.
README.markdown Updated README. Jan 22, 2013
link_test.go Go through all the pages on the repo list. Jan 9, 2013
setuphooks.go Use httputil for errors Aug 30, 2014


setuphooks is a commandline tool to set up github webhooks on repositories in bulk.

You can use it to add or remove a webhook destination to all of your personal repositories, repositories in any specific org you have access to, or individual repositories.

Hooks can be specified statically, or with a pattern (as I have different individual hooks for gitmirror for every repo, but they're all built roughly the same way).


This tool is written in go. To install it (assuming you have your go environment configured properly):

go get github.com/dustin/gitmirror/setuphooks


./setuphooks/setuphooks.mac [opts] template

  -T=false: Test all hooks
  -d=false: Delete, instead of adding a hook.
  -events="push": Comma separated list of events
  -n=false: If true, don't make any hook changes
  -org="": Organization to check
  -pass="": Your github password
  -repo="": Specific repo (default: all)
  -t=false: Test hooks when creating them
  -user="": Your github username
  -v=false: Print more stuff

Template parameters:
  {{.FullName}}     - full name of repo (e.g. dustin/gitmirror)
  {{.Id}}           - numeric ID of repo
  {{.Language}}     - repository language (if detected)
  {{.Name}}         - short name of repo (e.g. gitmirror)
  {{.Owner.Id}}     - github numeric id of repo owner
  {{.Owner.Login}}  - github username of repo owner

Example templates: