cli

package
v0.0.0-...-ec35b23 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(format string, a ...interface{})

Debug prints a message to console when verbose mode is chosen.

func Die

func Die(exitCode int, format string, a ...interface{})

Die prints a message and exists the process with exitCode.

func Print

func Print(format string, a ...interface{})

Print prints a message to console.

func Run

func Run()

Run is the main entry point for the versioner cli.

Types

type CommandConfig

type CommandConfig struct {
	LatestVersion LatestVersionCommandConfig `opts:"mode=cmd,help=Get latest version from git tags."`
	NextVersion   NextVersionCommandConfig   `opts:"mode=cmd,help=Get next for latest version from git tags."`
	Version       VersionCommandConfig       `opts:"mode=cmd,help=Get version of versioner."`
	Release       ReleaseCommandConfig       `opts:"mode=cmd,help=Perform a release (Tag and push)."`
}

CommandConfig describes sub commands and options of the versioner cli.

type LatestVersionCommandConfig

type LatestVersionCommandConfig struct {
}

LatestVersionCommandConfig is the command config for latest-version command.

func (*LatestVersionCommandConfig) Run

func (config *LatestVersionCommandConfig) Run() error

Run executes the latest-version command.

type NextVersionCommandConfig

type NextVersionCommandConfig struct {
}

NextVersionCommandConfig is the config for the next-version command.

func (*NextVersionCommandConfig) Run

func (config *NextVersionCommandConfig) Run() error

Run executes the next-version command.

type ReleaseCommandConfig

type ReleaseCommandConfig struct {
}

ReleaseCommandConfig is the config for the release command.

func (*ReleaseCommandConfig) Run

func (config *ReleaseCommandConfig) Run() error

Run executes the release command.

type VersionCommandConfig

type VersionCommandConfig struct {
	Long bool
}

VersionCommandConfig is the version command config.

func (*VersionCommandConfig) Run

func (config *VersionCommandConfig) Run() error

Run executes the version command.

Jump to

Keyboard shortcuts

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