summaryrefslogtreecommitdiff
path: root/dpass
blob: 60adce3237a2646216b90addc4b006518c973f0a (plain)
1
2
3
4
5
6
7
#!/bin/sh
# Select a password in dmenu and copy it

dir="${PASSWORD_STORE_DIR:-$HOME/.password-store}"
password=$(find "$dir" -type f -name '*.gpg' |
    sed 's/.*\/\(.*\)\.gpg$/\1/' | dmenu -i -p "Pass:")
[ -n "$password" ] && pass show -c "$password"