From d5ca913b2f78ea68f41d9f377a3bf4f37bc8ab0c Mon Sep 17 00:00:00 2001 From: Unknwon Date: Wed, 17 Feb 2016 15:05:07 -0500 Subject: [PATCH] #2639 add branch prefix for test webhook --- .gopmfile | 2 +- gogs.go | 2 +- routers/repo/webhook.go | 3 ++- templates/.VERSION | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.gopmfile b/.gopmfile index dfe1232e4..765d10030 100644 --- a/.gopmfile +++ b/.gopmfile @@ -15,7 +15,7 @@ github.com/go-macaron/session = commit:66031fc github.com/go-macaron/toolbox = commit:82b5115 github.com/go-sql-driver/mysql = commit:b4db83c github.com/go-xorm/core = commit:1e2868c -github.com/go-xorm/xorm = commit:24c1f3c +github.com/go-xorm/xorm = github.com/gogits/chardet = commit:2404f77725 github.com/gogits/git-module = commit:3b40eae github.com/gogits/go-gogs-client = diff --git a/gogs.go b/gogs.go index 30bcf695a..22d36b5bf 100644 --- a/gogs.go +++ b/gogs.go @@ -17,7 +17,7 @@ import ( "github.com/gogits/gogs/modules/setting" ) -const APP_VER = "0.8.37.0215" +const APP_VER = "0.8.37.0217" func init() { runtime.GOMAXPROCS(runtime.NumCPU()) diff --git a/routers/repo/webhook.go b/routers/repo/webhook.go index a1b363304..6d271a4fe 100644 --- a/routers/repo/webhook.go +++ b/routers/repo/webhook.go @@ -12,6 +12,7 @@ import ( "github.com/Unknwon/com" + git "github.com/gogits/git-module" api "github.com/gogits/go-gogs-client" "github.com/gogits/gogs/models" @@ -341,7 +342,7 @@ func SlackHooksEditPost(ctx *middleware.Context, form auth.NewSlackHookForm) { func TestWebhook(ctx *middleware.Context) { p := &api.PushPayload{ - Ref: ctx.Repo.Repository.DefaultBranch, + Ref: git.BRANCH_PREFIX + ctx.Repo.Repository.DefaultBranch, Before: ctx.Repo.CommitID, After: ctx.Repo.CommitID, Commits: []*api.PayloadCommit{ diff --git a/templates/.VERSION b/templates/.VERSION index a9a29980f..5b4bfc48e 100644 --- a/templates/.VERSION +++ b/templates/.VERSION @@ -1 +1 @@ -0.8.37.0215 \ No newline at end of file +0.8.37.0217 \ No newline at end of file