#!/bin/sh
cd "${PA_DIR:-$HOME/.local/share/pa/passwords}"
password_files="$(find * -type f | grep -v '/.git')"
password=$(printf '%s\n' "$password_files" | sed 's/.age//' | dmenu "$@")
pa show "$password" | head -n 1 |
xdotool type --clearmodifiers --file -