diff options
Diffstat (limited to 'cmd/web.go')
-rw-r--r-- | cmd/web.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/cmd/web.go b/cmd/web.go index 72a58bc995..810e36d3bb 100644 --- a/cmd/web.go +++ b/cmd/web.go @@ -313,6 +313,12 @@ func runWeb(*cli.Context) { r.Get("/hooks/:id", repo.WebHooksEdit) r.Post("/hooks/gogs/:id", bindIgnErr(auth.NewWebhookForm{}), repo.WebHooksEditPost) r.Post("/hooks/slack/:id", bindIgnErr(auth.NewSlackHookForm{}), repo.SlackHooksEditPost) + + m.Group("/hooks/git", func(r *macaron.Router) { + r.Get("", repo.GitHooks) + r.Get("/:name", repo.GitHooksEdit) + r.Post("/:name", repo.GitHooksEditPost) + }, middleware.GitHookService()) }) }, reqSignIn, middleware.RepoAssignment(true), reqTrueOwner) |