Documentation ¶
Index ¶
- Constants
- func ChangeVersion(version *semver.Version, change string) *semver.Version
- func Complete()
- func Debug(message string, args ...interface{})
- func DetectRelease() int
- func Fail(message string, args ...interface{})
- func Fatal(message string, args ...interface{})
- func FinishStep(code int)
- func GetCurrentVersion() *semver.Version
- func GetEmojiWidth() int64
- func GetVersions() semver.Collection
- func GitMustBeClean(reason string)
- func Info(message string, args ...interface{})
- func Log(destination *os.File, message string, args ...interface{})
- func LogWithIcon(destination *os.File, icon, message string, args ...interface{})
- func NotifyExecution(showOnly bool, showOnlyVerb, realVerb, message string, args ...interface{}) bool
- func NotifyStep(showOnly bool, color, showOnlyVerb, realVerb, message string, ...) bool
- func SaveChanges(newVersion, currentVersion *semver.Version, changes []Change, dryRun bool)
- func SpacedEmoji(emoji string) string
- func Success(message string, args ...interface{})
- func UpdateGemVersion(newVersion, currentVersion *semver.Version, commit, tag, dryRun bool)
- func UpdateNpmVersion(newVersion, currentVersion *semver.Version, commit, tag, dryRun bool)
- func UpdatePlainVersion(newVersion, currentVersion *semver.Version, commit, tag, dryRun bool)
- func UpdateVersion(newVersion, currentVersion *semver.Version, dryRun bool)
- func Warn(message string, args ...interface{})
- type Change
- type ExecutionResult
Constants ¶
const ( // PlainRelease releases using Git PlainRelease int = iota // NpmRelease releases using npm NpmRelease // GemRelease release using "rake release" task GemRelease )
Variables ¶
This section is empty.
Functions ¶
func ChangeVersion ¶
ChangeVersion changes the current version.
func Debug ¶ added in v1.1.0
func Debug(message string, args ...interface{})
Debug shows a debug message
func DetectRelease ¶
func DetectRelease() int
DetectRelease detects which kind of release we have to use
func Fatal ¶
func Fatal(message string, args ...interface{})
Fatal aborts the executable with a error message
func GetCurrentVersion ¶
GetCurrentVersion return the current version.
func GetVersions ¶
func GetVersions() semver.Collection
GetVersions return all current GIT versions.
func GitMustBeClean ¶
func GitMustBeClean(reason string)
GitMustBeClean checks that the current working copy has not uncommitted changes
func LogWithIcon ¶ added in v1.1.0
LogWithIcon shows a message with a custom icon
func NotifyExecution ¶
func NotifyExecution(showOnly bool, showOnlyVerb, realVerb, message string, args ...interface{}) bool
NotifyExecution notifies about a execution of a operation
func NotifyStep ¶
func NotifyStep(showOnly bool, color, showOnlyVerb, realVerb, message string, args ...interface{}) bool
NotifyStep notifies about a execution of a step
func SaveChanges ¶
SaveChanges persist changes from GIT to the CHANGELOG.md file.
func SpacedEmoji ¶ added in v1.1.0
SpacedEmoji returns an emoji with a trailing space
func UpdateGemVersion ¶
UpdateGemVersion updates the current version by manipulating the version file.
func UpdateNpmVersion ¶
UpdateNpmVersion updates the current version using NPM.
func UpdatePlainVersion ¶
UpdatePlainVersion updates the current version according to a plain managament.
func UpdateVersion ¶
UpdateVersion updates the current version.
Types ¶
type Change ¶
Change represents a git commit
func ListChanges ¶
ListChanges lists changes since the last version.
type ExecutionResult ¶
ExecutionResult represents a command execution result
func Execute ¶
func Execute(showOutput bool, cmd string, args ...string) (result ExecutionResult)
Execute executes a command.
func (ExecutionResult) Verify ¶
func (e ExecutionResult) Verify(executableName, failureMessage string)
Verify checks the command executed properly and exited with exit code 0