Compare commits
No commits in common. "7e4d50b7760536ae7d7272f65d3eab12a11e0eef" and "c9a8e38914ecd618da2b23152205a74e7a688c02" have entirely different histories.
7e4d50b776
...
c9a8e38914
|
|
@ -167,13 +167,6 @@ func promptHiddenRequired(prompt string) (string, error) {
|
|||
|
||||
func promptHiddenOptional(prompt string) (string, error) {
|
||||
fmt.Printf("%s: ", prompt)
|
||||
if !term.IsTerminal(int(syscall.Stdin)) {
|
||||
value, err := bufio.NewReader(os.Stdin).ReadString('\n')
|
||||
if err != nil && len(value) == 0 {
|
||||
return "", nil
|
||||
}
|
||||
return strings.TrimSpace(value), nil
|
||||
}
|
||||
value, err := term.ReadPassword(int(syscall.Stdin))
|
||||
fmt.Println()
|
||||
if err != nil {
|
||||
|
|
|
|||
Loading…
Reference in a new issue