Documentation ¶
Index ¶
- func AskBool(question string, defaultAnswer string) bool
- func AskChoice(question string, choices []string, defaultAnswer string) string
- func AskInt(question string, min int64, max int64, defaultAnswer string, ...) int64
- func AskPassword(question string) string
- func AskPasswordOnce(question string) string
- func AskString(question string, defaultAnswer string, validate func(string) error) string
- func FormatSection(header string, content string) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AskInt ¶
func AskInt(question string, min int64, max int64, defaultAnswer string, validate func(int64) error) int64
AskInt asks the user to enter an integer between a min and max value
func AskPassword ¶
AskPassword asks the user to enter a password.
func AskPasswordOnce ¶
AskPasswordOnce asks the user to enter a password.
It's the same as AskPassword, but it won't ask to enter it again.
func AskString ¶
AskString asks the user to enter a string, which optionally conforms to a validation function.
func FormatSection ¶
FormatSection properly indents a text section
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.