gitlab

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ProjectVariablesApi = "/projects/:id/variables"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Gitlab

type Gitlab struct {
	BaseUrl string
	ApiPath string
	Token   string
	Client  *http.Client
}

func NewGitlab

func NewGitlab(baseUrl string, apiPath string, token string, skipCertVerify bool) *Gitlab

func (*Gitlab) CreateProjectVariable

func (g *Gitlab) CreateProjectVariable(projectId string, variable *ProjectVariable) (*ProjectVariable, error)

func (*Gitlab) ListProjectVaribles

func (g *Gitlab) ListProjectVaribles(projectId string) (*ProjectVariablesList, error)

func (*Gitlab) ResourceUrl

func (g *Gitlab) ResourceUrl(path string, params map[string]string) *url.URL

type ProjectVariable

type ProjectVariable struct {
	VariableType     string `json:"variable_type,omitempty"`
	Key              string `json:"key"`
	Value            string `json:"value"`
	Protected        bool   `json:"protected,omitempty"`
	Masked           bool   `json:"masked,omitempty"`
	EnvironmentScope string `mapstructure:"environment_scope,omitempty"`
}

type ProjectVariablesList

type ProjectVariablesList struct {
	Items []ProjectVariable
}

Jump to

Keyboard shortcuts

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