Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
G
go-gitlab
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
go-gitlab
Commits
4f616cbc
Commit
4f616cbc
authored
Jul 25, 2018
by
Peter Shilo
Committed by
Sander van Harmelen
Jul 25, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
listtagopts added params (#436)
* listtagopts added params * test fix + gitignore
parent
81955e08
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
2 deletions
+7
-2
.gitignore
.gitignore
+1
-0
tags.go
tags.go
+5
-1
tags_test.go
tags_test.go
+1
-1
No files found.
.gitignore
View file @
4f616cbc
...
...
@@ -6,6 +6,7 @@
# Folders
_obj
_test
.idea
# Architecture specific extensions/prefixes
*.[568vq]
...
...
tags.go
View file @
4f616cbc
...
...
@@ -55,7 +55,11 @@ func (t Tag) String() string {
//
// GitLab API docs:
// https://docs.gitlab.com/ce/api/tags.html#list-project-repository-tags
type
ListTagsOptions
ListOptions
type
ListTagsOptions
struct
{
ListOptions
OrderBy
*
string
`url:"order_by,omitempty" json:"order_by,omitempty"`
Sort
*
string
`url:"sort,omitempty" json:"sort,omitempty"`
}
// ListTags gets a list of tags from a project, sorted by name in reverse
// alphabetical order.
...
...
tags_test.go
View file @
4f616cbc
...
...
@@ -16,7 +16,7 @@ func TestListTags(t *testing.T) {
fmt
.
Fprint
(
w
,
`[{"name": "1.0.0"},{"name": "1.0.1"}]`
)
})
opt
:=
&
ListTagsOptions
{
Page
:
2
,
PerPage
:
3
}
opt
:=
&
ListTagsOptions
{
ListOptions
:
ListOptions
{
Page
:
2
,
PerPage
:
3
}
}
tags
,
_
,
err
:=
client
.
Tags
.
ListTags
(
1
,
opt
)
if
err
!=
nil
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment