summaryrefslogtreecommitdiffstats
path: root/routers/api/v1/api.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2019-02-07 20:00:52 +0800
committerzeripath <art27@cantab.net>2019-02-07 12:00:52 +0000
commit01bbf5ea6940a1dc3793aaae2db2d85b1769432c (patch)
tree9bd5dbc9d0ffab32ec93334ad3f7e7eebe67a338 /routers/api/v1/api.go
parent2d213b64d1c897d7a0fdbc93e5cab90f84d7334a (diff)
downloadgitea-01bbf5ea6940a1dc3793aaae2db2d85b1769432c.tar.gz
gitea-01bbf5ea6940a1dc3793aaae2db2d85b1769432c.zip
Add API to list tags (#5850)
* Add API to list tags * update dependency gitea sdk vendor * fix swagger generation * fix swagger * add tests * update code.gitea.io/git vendor
Diffstat (limited to 'routers/api/v1/api.go')
-rw-r--r--routers/api/v1/api.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/routers/api/v1/api.go b/routers/api/v1/api.go
index c5a5488a81..89d277233f 100644
--- a/routers/api/v1/api.go
+++ b/routers/api/v1/api.go
@@ -513,6 +513,9 @@ func RegisterRoutes(m *macaron.Macaron) {
m.Get("", repo.ListBranches)
m.Get("/*", context.RepoRefByType(context.RepoRefBranch), repo.GetBranch)
}, reqRepoReader(models.UnitTypeCode))
+ m.Group("/tags", func() {
+ m.Get("", repo.ListTags)
+ }, reqRepoReader(models.UnitTypeCode))
m.Group("/keys", func() {
m.Combo("").Get(repo.ListDeployKeys).
Post(bind(api.CreateKeyOption{}), repo.CreateDeployKey)