Documentation
¶
Index ¶
- func GetVersion(options *GetVersionOptions) string
- func Init(options *InitOptions) (err error)
- func PredictVersion(options *PredictVersionOptions) (prediction string, err error)
- func PushVersion(options *PushVersionOptions) (err error)
- func ReleaseVersion(predictOptions *PredictVersionOptions) error
- func UpdateVersion(updateOptions *UpdateVersionOptions) error
- type GetVersionOptions
- type InitOptions
- type PredictVersionOptions
- type PushVersionOptions
- type UpdateVersionOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetVersion ¶
func GetVersion(options *GetVersionOptions) string
GetVersion gets the current version. Returns the current version.
func Init ¶
func Init(options *InitOptions) (err error)
Init initializes a config file with defaults. It will prompt for confirmation before overwriting existing files. Returns an error if something went wrong with IO operations or the prompt.
func PredictVersion ¶
func PredictVersion(options *PredictVersionOptions) (prediction string, err error)
PredictVersion predicts a version based on a modes.Mode and a modes.Map. The modes.Map values will be matched against git information to detect which semver level to increment. Returns the next version or an error if the prediction failed.
func PushVersion ¶
func PushVersion(options *PushVersionOptions) (err error)
PushVersion pushes the current version. Returns an error if the push went wrong.
func ReleaseVersion ¶
func ReleaseVersion(predictOptions *PredictVersionOptions) error
ReleaseVersion releases a new version. Returns an error if anything went wrong with the prediction or releasing.
func UpdateVersion ¶
func UpdateVersion(updateOptions *UpdateVersionOptions) error
UpdateVersion updates to the latest version. Returns an error if updating the version went wrong.
Types ¶
type GetVersionOptions ¶
type InitOptions ¶
type PredictVersionOptions ¶
type PushVersionOptions ¶
type UpdateVersionOptions ¶ added in v1.3.3
type UpdateVersionOptions struct {
GitTagsPrefix string
}