]> source.dussan.org Git - gitea.git/commitdiff
Add missing patch conflit pattern
authorUnknwon <u@gogs.io>
Wed, 3 Feb 2016 17:28:03 +0000 (12:28 -0500)
committerUnknwon <u@gogs.io>
Wed, 3 Feb 2016 17:28:03 +0000 (12:28 -0500)
README.md
gogs.go
models/pull.go
templates/.VERSION

index b7bb7b4db4fd776b3d04c62bcba5372055fb639d..6435af02a24e4bfa8da87adc4549421bd99a07ca 100644 (file)
--- a/README.md
+++ b/README.md
@@ -3,7 +3,7 @@ Gogs - Go Git Service [![Build Status](https://travis-ci.org/gogits/gogs.svg?bra
 
 ![](https://github.com/gogits/gogs/blob/master/public/img/gogs-large-resize.png?raw=true)
 
-##### Current version: 0.8.27
+##### Current version: 0.8.28
 
 | Web | UI  | Preview  |
 |:-------------:|:-------:|:-------:|
diff --git a/gogs.go b/gogs.go
index 6659e909eb2b16bc3d94f522e8cc2ccdf1181b9c..5f681368132a56777c725630cbd032a361409bb3 100644 (file)
--- a/gogs.go
+++ b/gogs.go
@@ -17,7 +17,7 @@ import (
        "github.com/gogits/gogs/modules/setting"
 )
 
-const APP_VER = "0.8.27.0202"
+const APP_VER = "0.8.28.0203"
 
 func init() {
        runtime.GOMAXPROCS(runtime.NumCPU())
index 47d80473a05a46a75c5fa4bdef065ff8f394d12d..330319f9a83c084aa2f5c5ec65bf22a94dd75b89 100644 (file)
@@ -256,6 +256,7 @@ var patchConflicts = []string{
        "patch does not apply",
        "already exists in working directory",
        "unrecognized input",
+       "error:",
 }
 
 // testPatch checks if patch can be merged to base repository without conflit.
@@ -279,7 +280,7 @@ func (pr *PullRequest) testPatch() (err error) {
                return nil
        }
 
-       log.Trace("PullRequest[%d].testPatch(patchPath): %s", pr.ID, patchPath)
+       log.Trace("PullRequest[%d].testPatch (patchPath): %s", pr.ID, patchPath)
 
        if err := pr.BaseRepo.UpdateLocalCopy(); err != nil {
                return fmt.Errorf("UpdateLocalCopy: %v", err)
@@ -287,7 +288,7 @@ func (pr *PullRequest) testPatch() (err error) {
 
        // Checkout base branch.
        _, stderr, err := process.ExecDir(-1, pr.BaseRepo.LocalCopyPath(),
-               fmt.Sprintf("PullRequest.Merge(git checkout): %v", pr.BaseRepo.ID),
+               fmt.Sprintf("PullRequest.Merge (git checkout): %v", pr.BaseRepo.ID),
                "git", "checkout", pr.BaseBranch)
        if err != nil {
                return fmt.Errorf("git checkout: %s", stderr)
@@ -295,12 +296,12 @@ func (pr *PullRequest) testPatch() (err error) {
 
        pr.Status = PULL_REQUEST_STATUS_CHECKING
        _, stderr, err = process.ExecDir(-1, pr.BaseRepo.LocalCopyPath(),
-               fmt.Sprintf("testPatch(git apply --check): %d", pr.BaseRepo.ID),
+               fmt.Sprintf("testPatch (git apply --check): %d", pr.BaseRepo.ID),
                "git", "apply", "--check", patchPath)
        if err != nil {
                for i := range patchConflicts {
                        if strings.Contains(stderr, patchConflicts[i]) {
-                               log.Trace("PullRequest[%d].testPatch(apply): has conflit", pr.ID)
+                               log.Trace("PullRequest[%d].testPatch (apply): has conflit", pr.ID)
                                fmt.Println(stderr)
                                pr.Status = PULL_REQUEST_STATUS_CONFLICT
                                return nil
index 859d0a255571f23fd1786c3d2de3dd15bf58c25f..9c1b3c01c1e31ab9da4022a7eb5154b11a731f12 100644 (file)
@@ -1 +1 @@
-0.8.27.0202
\ No newline at end of file
+0.8.28.0203
\ No newline at end of file