Vendor Update: go-gitlab v0.22.1 -> v0.31.0 (#11136)
* vendor update: go-gitlab to v0.31.0 * migrate client init to v0.31.0 * refactor
This commit is contained in:
parent
5c092eb0ef
commit
82dbb34c9c
256 changed files with 36039 additions and 12965 deletions
14
vendor/github.com/xanzy/go-gitlab/snippets.go
generated
vendored
14
vendor/github.com/xanzy/go-gitlab/snippets.go
generated
vendored
|
@ -64,7 +64,7 @@ type ListSnippetsOptions ListOptions
|
|||
// ListSnippets gets a list of snippets.
|
||||
//
|
||||
// GitLab API docs: https://docs.gitlab.com/ce/api/snippets.html#list-snippets
|
||||
func (s *SnippetsService) ListSnippets(opt *ListSnippetsOptions, options ...OptionFunc) ([]*Snippet, *Response, error) {
|
||||
func (s *SnippetsService) ListSnippets(opt *ListSnippetsOptions, options ...RequestOptionFunc) ([]*Snippet, *Response, error) {
|
||||
req, err := s.client.NewRequest("GET", "snippets", opt, options)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
|
@ -83,7 +83,7 @@ func (s *SnippetsService) ListSnippets(opt *ListSnippetsOptions, options ...Opti
|
|||
//
|
||||
// GitLab API docs:
|
||||
// https://docs.gitlab.com/ce/api/snippets.html#single-snippet
|
||||
func (s *SnippetsService) GetSnippet(snippet int, options ...OptionFunc) (*Snippet, *Response, error) {
|
||||
func (s *SnippetsService) GetSnippet(snippet int, options ...RequestOptionFunc) (*Snippet, *Response, error) {
|
||||
u := fmt.Sprintf("snippets/%d", snippet)
|
||||
|
||||
req, err := s.client.NewRequest("GET", u, nil, options)
|
||||
|
@ -117,7 +117,7 @@ type CreateSnippetOptions struct {
|
|||
//
|
||||
// GitLab API docs:
|
||||
// https://docs.gitlab.com/ce/api/snippets.html#create-new-snippet
|
||||
func (s *SnippetsService) CreateSnippet(opt *CreateSnippetOptions, options ...OptionFunc) (*Snippet, *Response, error) {
|
||||
func (s *SnippetsService) CreateSnippet(opt *CreateSnippetOptions, options ...RequestOptionFunc) (*Snippet, *Response, error) {
|
||||
req, err := s.client.NewRequest("POST", "snippets", opt, options)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
|
@ -149,7 +149,7 @@ type UpdateSnippetOptions struct {
|
|||
//
|
||||
// GitLab API docs:
|
||||
// https://docs.gitlab.com/ce/api/snippets.html#update-snippet
|
||||
func (s *SnippetsService) UpdateSnippet(snippet int, opt *UpdateSnippetOptions, options ...OptionFunc) (*Snippet, *Response, error) {
|
||||
func (s *SnippetsService) UpdateSnippet(snippet int, opt *UpdateSnippetOptions, options ...RequestOptionFunc) (*Snippet, *Response, error) {
|
||||
u := fmt.Sprintf("snippets/%d", snippet)
|
||||
|
||||
req, err := s.client.NewRequest("PUT", u, opt, options)
|
||||
|
@ -172,7 +172,7 @@ func (s *SnippetsService) UpdateSnippet(snippet int, opt *UpdateSnippetOptions,
|
|||
//
|
||||
// GitLab API docs:
|
||||
// https://docs.gitlab.com/ce/api/snippets.html#delete-snippet
|
||||
func (s *SnippetsService) DeleteSnippet(snippet int, options ...OptionFunc) (*Response, error) {
|
||||
func (s *SnippetsService) DeleteSnippet(snippet int, options ...RequestOptionFunc) (*Response, error) {
|
||||
u := fmt.Sprintf("snippets/%d", snippet)
|
||||
|
||||
req, err := s.client.NewRequest("DELETE", u, nil, options)
|
||||
|
@ -187,7 +187,7 @@ func (s *SnippetsService) DeleteSnippet(snippet int, options ...OptionFunc) (*Re
|
|||
//
|
||||
// GitLab API docs:
|
||||
// https://docs.gitlab.com/ce/api/snippets.html#snippet-content
|
||||
func (s *SnippetsService) SnippetContent(snippet int, options ...OptionFunc) ([]byte, *Response, error) {
|
||||
func (s *SnippetsService) SnippetContent(snippet int, options ...RequestOptionFunc) ([]byte, *Response, error) {
|
||||
u := fmt.Sprintf("snippets/%d/raw", snippet)
|
||||
|
||||
req, err := s.client.NewRequest("GET", u, nil, options)
|
||||
|
@ -214,7 +214,7 @@ type ExploreSnippetsOptions ListOptions
|
|||
//
|
||||
// GitLab API docs:
|
||||
// https://docs.gitlab.com/ce/api/snippets.html#explore-all-public-snippets
|
||||
func (s *SnippetsService) ExploreSnippets(opt *ExploreSnippetsOptions, options ...OptionFunc) ([]*Snippet, *Response, error) {
|
||||
func (s *SnippetsService) ExploreSnippets(opt *ExploreSnippetsOptions, options ...RequestOptionFunc) ([]*Snippet, *Response, error) {
|
||||
req, err := s.client.NewRequest("GET", "snippets/public", nil, options)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue