Documentation
¶
Index ¶
- type Gitea
- func (g *Gitea) Add(files []string) error
- func (g *Gitea) Checkout() error
- func (g *Gitea) Clean() error
- func (g *Gitea) Clone() (string, error)
- func (g *Gitea) Commit(message string) error
- func (g *Gitea) GetChangedFiles(workingDir string) ([]string, error)
- func (g *Gitea) GetDirectory() (directory string)
- func (g *Gitea) IsRemoteBranchUpToDate() (bool, error)
- func (g *Gitea) Push() error
- func (g *Gitea) PushBranch(branch string) error
- func (g *Gitea) PushTag(tag string) error
- func (g *Gitea) SearchTags() (tags []string, err error)
- type Spec
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Gitea ¶
type Gitea struct {
// Spec contains inputs coming from updatecli configuration
Spec Spec
HeadBranch string
// contains filtered or unexported fields
}
Gitea contains information to interact with Gitea api
func (*Gitea) GetChangedFiles ¶
func (*Gitea) GetDirectory ¶
GetDirectory returns the local git repository path.
func (*Gitea) IsRemoteBranchUpToDate ¶ added in v0.45.0
IsRemoteBranchUpToDate checks if the branch reference name is published on on the default remote
func (*Gitea) Push ¶
Push run `git push` to the corresponding Gitea remote branch if not already created.
func (*Gitea) PushBranch ¶ added in v0.44.0
PushBranch push branch
func (*Gitea) SearchTags ¶
Retrieve git tags from a remote gitea 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 Gitea repository branch to work on
Branch string `yaml:",omitempty"`
}
Spec defines settings used to interact with Gitea release
Click to show internal directories.
Click to hide internal directories.