#!/bin/sh
set -eu

choice="$(find ~/.password-store/ -type f -name '*.gpg'          |
            sed -e "s|^$HOME/.password-store/||" -e 's/\.gpg$//' |
            dmenu -l 20 -i -p 'Pass: ' -fn Monospace-18)"

if [ -n "$choice" ]; then
	pass show -c2 "$choice"
fi
