diff options
author | Sandro Santilli <strk@kbt.io> | 2016-11-05 22:54:20 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-11-05 22:54:20 +0100 |
commit | f36544f98db4a210195f7d0f9019d64d9dff72f3 (patch) | |
tree | 46513d09162e3715d69a015da9cf7f225dc9c6b5 /cmd | |
parent | 953c099428b152a85102f07fd2ecfe19d54ee973 (diff) | |
parent | a0e54c0512a764ab0f93eb2ee6b978fb736190b4 (diff) | |
download | gitea-f36544f98db4a210195f7d0f9019d64d9dff72f3.tar.gz gitea-f36544f98db4a210195f7d0f9019d64d9dff72f3.zip |
Merge branch 'master' into feature/goimports
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/web.go | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/cmd/web.go b/cmd/web.go index dbade23b57..580fae1cb6 100644 --- a/cmd/web.go +++ b/cmd/web.go @@ -518,7 +518,8 @@ func runWeb(ctx *cli.Context) error { ctx.Data["CommitsCount"] = ctx.Repo.CommitsCount }) - m.Combo("/compare/*", repo.MustAllowPulls).Get(repo.CompareAndPullRequest). + m.Combo("/compare/*", repo.MustAllowPulls, repo.SetEditorconfigIfExists). + Get(repo.CompareAndPullRequest). Post(bindIgnErr(auth.CreateIssueForm{}), repo.CompareAndPullRequestPost) m.Group("", func() { @@ -577,15 +578,15 @@ func runWeb(ctx *cli.Context) error { m.Group("/pulls/:index", func() { m.Get("/commits", context.RepoRef(), repo.ViewPullCommits) - m.Get("/files", context.RepoRef(), repo.ViewPullFiles) + m.Get("/files", context.RepoRef(), repo.SetEditorconfigIfExists, repo.ViewPullFiles) m.Post("/merge", reqRepoWriter, repo.MergePullRequest) }, repo.MustAllowPulls) m.Group("", func() { - m.Get("/src/*", repo.Home) + m.Get("/src/*", repo.SetEditorconfigIfExists, repo.Home) m.Get("/raw/*", repo.SingleDownload) m.Get("/commits/*", repo.RefCommits) - m.Get("/commit/:sha([a-f0-9]{7,40})$", repo.Diff) + m.Get("/commit/:sha([a-f0-9]{7,40})$", repo.SetEditorconfigIfExists, repo.Diff) m.Get("/forks", repo.Forks) }, context.RepoRef()) m.Get("/commit/:sha([a-f0-9]{7,40})\\.:ext(patch|diff)", repo.RawDiff) @@ -599,8 +600,8 @@ func runWeb(ctx *cli.Context) error { m.Group("/:username", func() { m.Group("/:reponame", func() { - m.Get("", repo.Home) - m.Get("\\.git$", repo.Home) + m.Get("", repo.SetEditorconfigIfExists, repo.Home) + m.Get("\\.git$", repo.SetEditorconfigIfExists, repo.Home) }, ignSignIn, context.RepoAssignment(true), context.RepoRef()) m.Group("/:reponame", func() { |