gitscm

package
v0.18.2 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2022 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateTag

func CreateTag(annonation string, message string) (bool, error)

func CreateTagFrom

func CreateTagFrom(annonation, commit, message string) (bool, error)

func FormatCommit

func FormatCommit(messages map[string]string) (string, error)

func IsGitInstalled added in v0.10.0

func IsGitInstalled() bool

func IsGitRepository added in v0.12.0

func IsGitRepository() bool

func IsStageAreaEmpty added in v0.12.0

func IsStageAreaEmpty() bool

Types

type Git

type Git struct {
	Tags       []string
	GitTags    []GitTag
	GitCommits []GitCommit
	Command    map[string]cmd.InternalCommand
}

func New

func New() (Git, error)

func (Git) IsTagsEmpty

func (git Git) IsTagsEmpty() bool

func (*Git) LastestTag

func (git *Git) LastestTag() (GitTag, bool)

type GitCommit

type GitCommit struct {
	Author  string
	Date    string
	Hash    string
	Message string
}

func LoadCommitFromBegin

func LoadCommitFromBegin() ([]GitCommit, error)

func LoadCommitsFrom

func LoadCommitsFrom(beginFromCommit string) ([]GitCommit, error)

type GitTag

type GitTag struct {
	Stamp      string
	Annotation string
	Author     string
	Commit     GitCommit
	Date       string
}

type GitTagGroup

type GitTagGroup []GitTag

func (GitTagGroup) Len

func (version GitTagGroup) Len() int

func (GitTagGroup) Less

func (version GitTagGroup) Less(i, j int) bool

func (GitTagGroup) Swap

func (version GitTagGroup) Swap(i, j int)

Jump to

Keyboard shortcuts

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