ingress-nginx-helm/vendor/github.com/howeyc/gopass
Manuel de Brito Fontes 1bc383f9c5 Update godeps
2016-11-11 18:22:34 -03:00
..
.travis.yml Update godeps 2016-11-11 18:22:34 -03:00
LICENSE.txt Update godeps 2016-11-11 18:22:34 -03:00
OPENSOLARIS.LICENSE Update godeps 2016-11-11 18:22:34 -03:00
pass.go Update godeps 2016-11-11 18:22:34 -03:00
README.md Update godeps 2016-11-11 18:22:34 -03:00
terminal.go Update godeps 2016-11-11 18:22:34 -03:00
terminal_solaris.go Update godeps 2016-11-11 18:22:34 -03:00

getpasswd in Go GoDoc Build Status

Retrieve password from user terminal or piped input without echo.

Verified on BSD, Linux, and Windows.

Example:

package main

import "fmt"
import "github.com/howeyc/gopass"

func main() {
	fmt.Printf("Password: ")

	// Silent. For printing *'s use gopass.GetPasswdMasked()
	pass, err := gopass.GetPasswd()
	if err != nil {
		// Handle gopass.ErrInterrupted or getch() read error
	}

	// Do something with pass
}

Caution: Multi-byte characters not supported!