utils

package
v0.0.0-...-bc6c432 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GitlabApi

type GitlabApi struct {
	Client *gitlab.Client
}

GitlabApi is our wrapper tool around gitlab.Client

func NewGitlabApi

func NewGitlabApi(httpClient *http.Client, apiBaseURL string, privateToken string) *GitlabApi

NewGitlabApi creates a new gitlab api and returns it

func (*GitlabApi) AddMembers

func (h *GitlabApi) AddMembers(project *gitlab.Project, perm *gitlab.AccessLevelValue, members ...*gitlab.User) error

func (*GitlabApi) CreateProjects

func (h *GitlabApi) CreateProjects(gitlabOwners []string, gitlabGroup string, gitlabProjects []string) error

func (*GitlabApi) DisabledDeployKey

func (h *GitlabApi) DisabledDeployKey(deployKey *gitlab.DeployKey, idProject int) error

func (*GitlabApi) EnableDeployKey

func (h *GitlabApi) EnableDeployKey(deployKey *gitlab.DeployKey, idProject int) error

func (*GitlabApi) EnumAllGroupsProjects

func (h *GitlabApi) EnumAllGroupsProjects() (<-chan *gitlab.Project, <-chan error)

func (*GitlabApi) EnumGroupProjects

func (h *GitlabApi) EnumGroupProjects(group *gitlab.Group) (<-chan *gitlab.Project, <-chan error)

func (*GitlabApi) EnumGroups

func (h *GitlabApi) EnumGroups() (<-chan *gitlab.Group, <-chan error)

func (*GitlabApi) EnumGroupsProjects

func (h *GitlabApi) EnumGroupsProjects(groups <-chan *gitlab.Group) (<-chan *gitlab.Project, <-chan error)

func (*GitlabApi) GetDeployKey

func (h *GitlabApi) GetDeployKey(idProject, idDeployKey int) (*gitlab.DeployKey, error)

func (*GitlabApi) GetUser

func (h *GitlabApi) GetUser(username string) (*gitlab.User, error)

func (*GitlabApi) ListAllGroupsProjects

func (h *GitlabApi) ListAllGroupsProjects() ([]*gitlab.Project, error)

func (*GitlabApi) ListDeployKeys

func (h *GitlabApi) ListDeployKeys(idProject int) ([]*gitlab.DeployKey, error)

func (*GitlabApi) ListGroupProjects

func (h *GitlabApi) ListGroupProjects(group *gitlab.Group) ([]*gitlab.Project, error)

func (*GitlabApi) ListGroups

func (h *GitlabApi) ListGroups(opts *gitlab.ListGroupsOptions) ([]*gitlab.Group, error)

func (*GitlabApi) ListProjectBranches

func (h *GitlabApi) ListProjectBranches(project *gitlab.Project) ([]*gitlab.Branch, error)

func (*GitlabApi) ListProjectTags

func (h *GitlabApi) ListProjectTags(project *gitlab.Project) ([]*gitlab.Tag, error)

func (*GitlabApi) ListTree

func (h *GitlabApi) ListTree(project *gitlab.Project, ref string, path string) ([]*Node, error)

func (*GitlabApi) ReplaceOwners

func (h *GitlabApi) ReplaceOwners(project *gitlab.Project, owners ...*gitlab.User) error

type Node

type Node struct {
	Path     string
	TreeNode *gitlab.TreeNode
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL