semantic

package
v0.0.0-...-49dbbda Latest Latest
Warning

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

Go to latest
Published: Dec 26, 2020 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Commit

type Commit struct {
	Version SemanticVersion
	Hash    string
	Type    string
	Scope   string
	Message string
}

type ReleaseInfo

type ReleaseInfo struct {
	// string representation of latest released version
	LatestVersion string
	// string representation of next possible version
	// will be empty if semantic commits does not exist
	// possible tag of current commit
	CurrentTag  string
	NextVersion string
	// List of commits since current version
	NextCommits []Commit
}

ReleaseInfo contains information about commit considered as release

type Repository

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

func New

func New(repoPath string) (*Repository, error)

func (*Repository) Info

func (r *Repository) Info() (ReleaseInfo, error)

Info returns semantic information about selected repository

func (*Repository) PushExperimental

func (r *Repository) PushExperimental(user, password, key string) error

PushExperimental pushes code to remote repository using provided credentials can be usefull in some CI cases

type SemanticVersion

type SemanticVersion uint8
const (
	VersionInvalid SemanticVersion = iota
	VersionNone
	VersionPatch
	VersionMinor
	VersionMajor
)

Jump to

Keyboard shortcuts

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