repository

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrCommitNotFound = errors.New("commit not found")

ErrCommitNotFound indicates missing commits since last tag to generate new tag.

Functions

This section is empty.

Types

type Message

type Message map[string]string

Message is a key-value store of commit message parameters, where key is the name of provided in template field and value - matching pattern text.

func ParseMessage

func ParseMessage(template, message string, required ...string) (Message, error)

ParseMessage returns message with parsed from template and commit message parameters.

type Repository

type Repository struct {
	// contains filtered or unexported fields
}

Repository works on git repository and handles all features related strictly with git.

func Open

func Open(path string) (*Repository, error)

Open returns git repository if exists, otherwise fails with an error.

func (*Repository) CreateTag

func (r *Repository) CreateTag(name string) error

CreateTag is an equivalent to "git tag <name>".

func (*Repository) FeatureCommits

func (r *Repository) FeatureCommits() ([]string, error)

FeatureCommits returns commits since last known tag.

func (*Repository) LatestTag

func (r *Repository) LatestTag() (string, error)

LatestTag returns latest known in repository tag.

Jump to

Keyboard shortcuts

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