blob: 568570e0a7f95f3ed35979563798ac9f0014bd68 (
plain) (
tree)
|
|
#!/bin/sh
usage () {
cat >&2 <<-EOF
usage: ${0} password_regexp
EOF
}
log () {
echo ["${0}"] $@ >&2
}
main() {
# verify arguments
[ "${#}" -ne 1 ] && usage && exit 1
# retrieve password
log "retrieving password for : ${1}"
gopass show --password $(gopass ls --flat | grep "${1}" | head -n 1)
}
main $@
|