Documentation ¶
Overview ¶
Package turban offers a simple shell experience.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrInvalidUsage when returned by the Run Command function, // then usage is printed. ErrInvalidUsage = errors.New("invalid usage") )
Functions ¶
func AddCommand ¶
AddCommand register a new shell command.
func AskForConfirmation ¶
AskForConfirmation asks the user for confirmation. A user must type in "yes" or "no" and then press enter. It has fuzzy matching, so "y", "Y", "yes", "YES", and "Yes" all count as confirmations. If the input is not recognized, it will ask again. The function does not return until it gets a valid response from the user.
func SetHelpHeader ¶
func SetHelpHeader(h string)
SetHelpHeader sets the header displayed in the help.
func SetPrintASCIIArtFunc ¶
func SetPrintASCIIArtFunc(f func())
SetPrintASCIIArtFunc sets the function which is called when the ASCII art logo should be printed.
Types ¶
Click to show internal directories.
Click to hide internal directories.