aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2018-12-16 19:48:34 -0500
committerUnknwon <u@gogs.io>2018-12-16 19:48:34 -0500
commitc82ac420fc86f454700f9f6e6148ed27a6f185cd (patch)
treeaaf04bca4108a6229faa35a160b85fa9b1c36f53
parentf91cb9321e06cf3570ca373e16ca84804ef7950a (diff)
vendor: update
- github.com/gogs/go-gogs-client - gopkg.in/macaron.v1
-rw-r--r--vendor/github.com/gogs/go-gogs-client/media_types.go9
-rw-r--r--vendor/github.com/gogs/go-gogs-client/repo_commit.go7
-rw-r--r--vendor/gopkg.in/macaron.v1/README.md2
-rw-r--r--vendor/gopkg.in/macaron.v1/context.go4
-rw-r--r--vendor/gopkg.in/macaron.v1/macaron.go2
-rw-r--r--vendor/vendor.json12
6 files changed, 26 insertions, 10 deletions
diff --git a/vendor/github.com/gogs/go-gogs-client/media_types.go b/vendor/github.com/gogs/go-gogs-client/media_types.go
new file mode 100644
index 00000000..884a8a74
--- /dev/null
+++ b/vendor/github.com/gogs/go-gogs-client/media_types.go
@@ -0,0 +1,9 @@
+// Copyright 2018 The Gogs Authors. All rights reserved.
+// Use of this source code is governed by a MIT-style
+// license that can be found in the LICENSE file.
+
+package gogs
+
+const (
+ MediaApplicationSHA = "application/vnd.gogs.sha"
+)
diff --git a/vendor/github.com/gogs/go-gogs-client/repo_commit.go b/vendor/github.com/gogs/go-gogs-client/repo_commit.go
index bd1a0804..b415962a 100644
--- a/vendor/github.com/gogs/go-gogs-client/repo_commit.go
+++ b/vendor/github.com/gogs/go-gogs-client/repo_commit.go
@@ -6,6 +6,7 @@ package gogs
import (
"fmt"
+ "net/http"
)
// CommitMeta contains meta information of a commit in terms of API.
@@ -44,3 +45,9 @@ func (c *Client) GetSingleCommit(user, repo, commitID string) (*Commit, error) {
commit := new(Commit)
return commit, c.getParsedResponse("GET", fmt.Sprintf("/repos/%s/%s/commits/%s", user, repo, commitID), nil, nil, &commit)
}
+
+func (c *Client) GetReferenceSHA(user, repo, ref string) (string, error) {
+ data, err := c.getResponse("GET", fmt.Sprintf("/repos/%s/%s/commits/%s", user, repo, ref),
+ http.Header{"Accept": []string{MediaApplicationSHA}}, nil)
+ return string(data), err
+}
diff --git a/vendor/gopkg.in/macaron.v1/README.md b/vendor/gopkg.in/macaron.v1/README.md
index b395b389..d2613c88 100644
--- a/vendor/gopkg.in/macaron.v1/README.md
+++ b/vendor/gopkg.in/macaron.v1/README.md
@@ -7,7 +7,7 @@ Package macaron is a high productive and modular web framework in Go.
## Getting Started
-The minimum requirement of Go is **1.3**.
+The minimum requirement of Go is **1.6**.
To install Macaron:
diff --git a/vendor/gopkg.in/macaron.v1/context.go b/vendor/gopkg.in/macaron.v1/context.go
index 94a8c45d..063f9e01 100644
--- a/vendor/gopkg.in/macaron.v1/context.go
+++ b/vendor/gopkg.in/macaron.v1/context.go
@@ -262,7 +262,7 @@ func (ctx *Context) Params(name string) string {
// SetParams sets value of param with given name.
func (ctx *Context) SetParams(name, val string) {
- if !strings.HasPrefix(name, ":") {
+ if name != "*" && !strings.HasPrefix(name, ":") {
name = ":" + name
}
ctx.params[name] = val
@@ -270,7 +270,7 @@ func (ctx *Context) SetParams(name, val string) {
// ReplaceAllParams replace all current params with given params
func (ctx *Context) ReplaceAllParams(params Params) {
- ctx.params = params;
+ ctx.params = params
}
// ParamsEscape returns escapred params result.
diff --git a/vendor/gopkg.in/macaron.v1/macaron.go b/vendor/gopkg.in/macaron.v1/macaron.go
index bd1b5a31..715076ac 100644
--- a/vendor/gopkg.in/macaron.v1/macaron.go
+++ b/vendor/gopkg.in/macaron.v1/macaron.go
@@ -32,7 +32,7 @@ import (
"github.com/go-macaron/inject"
)
-const _VERSION = "1.3.1.0306"
+const _VERSION = "1.3.2.1216"
func Version() string {
return _VERSION
diff --git a/vendor/vendor.json b/vendor/vendor.json
index 53bf80b1..1868ab2e 100644
--- a/vendor/vendor.json
+++ b/vendor/vendor.json
@@ -219,10 +219,10 @@
"revisionTime": "2018-12-15T04:53:36Z"
},
{
- "checksumSHA1": "LlzYU6W68aX9nJLibQkKFTiY+9Q=",
+ "checksumSHA1": "81S19W6omjG5N+zVWeI2yRsSfw0=",
"path": "github.com/gogs/go-gogs-client",
- "revision": "61758abf1cdb964b69de42a3f83f7148e3f9454d",
- "revisionTime": "2018-12-15T05:23:13Z"
+ "revision": "1cd0db3113de87dbac702b9f1a08d9bd0e7142bb",
+ "revisionTime": "2018-12-17T00:43:19Z"
},
{
"checksumSHA1": "GaJLoEuMGnP5ofXvuweAI4wx06U=",
@@ -711,10 +711,10 @@
"revisionTime": "2016-08-08T14:54:09Z"
},
{
- "checksumSHA1": "7c6yCe2PjyV+/qWiPBWUf+j+1us=",
+ "checksumSHA1": "55kJCeuwX46fYJt2Ww1d7rxMOTo=",
"path": "gopkg.in/macaron.v1",
- "revision": "c1be95e6d21e769e44e1ec33cec9da5837861c10",
- "revisionTime": "2018-03-06T06:20:08Z"
+ "revision": "dfcb80ca86e8534962c62812efd93209c7e600e7",
+ "revisionTime": "2018-12-17T00:30:54Z"
},
{
"checksumSHA1": "6QPjE+qflEBHg+JPJd9e4iQuRAk=",