Documentation
¶
Index ¶
- type Gitlab
- func (g *Gitlab) Add(files []string) error
- func (g *Gitlab) Checkout() error
- func (g *Gitlab) Clean() error
- func (g *Gitlab) Clone() (string, error)
- func (g *Gitlab) Commit(message string) error
- func (g *Gitlab) GetChangedFiles(workingDir string) ([]string, error)
- func (g *Gitlab) GetDirectory() (directory string)
- func (g *Gitlab) IsRemoteBranchUpToDate() (bool, error)
- func (g *Gitlab) Push() error
- func (g *Gitlab) PushBranch(branch string) error
- func (g *Gitlab) PushTag(tag string) error
- func (g *Gitlab) SearchTags() (tags []string, err error)
- type Spec
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Gitlab ¶
type Gitlab struct {
// Spec contains inputs coming from updatecli configuration
Spec Spec
HeadBranch string
// contains filtered or unexported fields
}
Gitlab contains information to interact with GitLab api
func (*Gitlab) GetChangedFiles ¶
func (*Gitlab) GetDirectory ¶
GetDirectory returns the local git repository path.
func (*Gitlab) IsRemoteBranchUpToDate ¶
IsRemoteBranchUpToDate checks if the branch reference name is published on on the default remote
func (*Gitlab) Push ¶
Push run `git push` to the corresponding GitLab remote branch if not already created.
func (*Gitlab) SearchTags ¶
Retrieve git tags from a remote gitlab repository
type Spec ¶
type Spec struct {
client.Spec `yaml:",inline,omitempty"`
// CommitMessage represents conventional commit metadata as type or scope, used to generate the final commit message.
CommitMessage commit.Commit `yaml:",omitempty"`
// Directory specifies where the github repository is cloned on the local disk
Directory string `yaml:",omitempty"`
// Email specifies which emails to use when creating commits
Email string `yaml:",omitempty"`
// Force is used during the git push phase to run `git push --force`.
Force bool `yaml:",omitempty"`
// GPG key and passphrased used for commit signing
GPG sign.GPGSpec `yaml:",omitempty"`
// Owner specifies repository owner
Owner string `yaml:",omitempty" jsonschema:"required"`
// Repository specifies the name of a repository for a specific owner
Repository string `yaml:",omitempty" jsonschema:"required"`
// User specifies the user of the git commit messages
User string `yaml:",omitempty"`
// Branch specifies which GitLab repository branch to work on
Branch string `yaml:",omitempty"`
}
Spec defines settings used to interact with GitLab release
Click to show internal directories.
Click to hide internal directories.