refactor: readability
This commit is contained in:
parent
ef4383209e
commit
3d100093dc
|
@ -17,16 +17,20 @@ func PromptBumpType(tagString string) error {
|
||||||
minor: new features/bug fixes, backwards compatible
|
minor: new features/bug fixes, backwards compatible
|
||||||
patch: bug fixes, backwards compatible
|
patch: bug fixes, backwards compatible
|
||||||
`)
|
`)
|
||||||
|
|
||||||
var chosenBumpType string
|
var chosenBumpType string
|
||||||
prompt := &survey.Select{
|
prompt := &survey.Select{
|
||||||
Message: fmt.Sprintf("select recipe version increment type"),
|
Message: fmt.Sprintf("select recipe version increment type"),
|
||||||
Options: []string{"major", "minor", "patch"},
|
Options: []string{"major", "minor", "patch"},
|
||||||
}
|
}
|
||||||
|
|
||||||
if err := survey.AskOne(prompt, &chosenBumpType); err != nil {
|
if err := survey.AskOne(prompt, &chosenBumpType); err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
SetBumpType(chosenBumpType)
|
SetBumpType(chosenBumpType)
|
||||||
}
|
}
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue