Documentation
¶
Index ¶
- Variables
- func Args(fn func(cmd *Command)) func(cmd *Command) *Command
- func GetPasswd(prompt ...string) ([]byte, error)
- func GetPasswdMasked(prompt ...string) ([]byte, error)
- func GetPasswdPrompt(prompt string, mask bool, r fdReader, w io.Writer) ([]byte, error)
- func Init(cfn ...func(cmd *Command)) func(...string)
- type Command
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInterrupted = errors.New("interrupted") ErrMaxLengthExceeded = fmt.Errorf("maximum byte limit (%v) exceeded", maxLength) )
Functions ¶
func GetPasswd ¶
GetPasswd returns the password read from the terminal without echoing input. The returned byte array does not include end-of-line characters.
func GetPasswdMasked ¶
GetPasswdMasked returns the password read from the terminal, echoing asterisks. The returned byte array does not include end-of-line characters.
func GetPasswdPrompt ¶
GetPasswdPrompt prompts the user and returns the password read from the terminal. If mask is true, then asterisks are echoed. The returned byte array does not include end-of-line characters.
Types ¶
Click to show internal directories.
Click to hide internal directories.