Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HookExec ¶
type HookExec struct { RootDir string Owner string Repo string Event string Data io.ReadSeeker HookServer *HookServer }
HookExec represents a call to a hook
func (*HookExec) GetPathExecs ¶
GetPathExecs fetches the executable filenames for the given path
type HookJSON ¶
type HookJSON struct { Repository struct { Name string `json:"name"` Owner HookUserJSON `json:"owner"` } `json:"repository"` Sender HookUserJSON `json:"sender"` }
HookJSON represents the minimum body we need to parse
type HookServer ¶
type HookServer struct { RootDir string Timeout time.Duration sync.Mutex // contains filtered or unexported fields }
HookServer implements net/http.Handler
func NewHookServer ¶
func NewHookServer(rootdir, secret string, timeout time.Duration) (*HookServer, error)
NewHookServer instantiates a new HookServer with some basic validation on the root directory
func (*HookServer) ServeHTTP ¶
func (h *HookServer) ServeHTTP(w http.ResponseWriter, r *http.Request)
type HookUserJSON ¶
HookUserJSON exists because some hooks use Login, some use Name - it's horribly inconsistent
func (*HookUserJSON) GetLogin ¶
func (h *HookUserJSON) GetLogin() string
GetLogin is used to get the login from the data github decided to pass today
Click to show internal directories.
Click to hide internal directories.