Getting an up-to-date GPG with Nix to get pass
to work
# install tools with nix
nix-env -iA nixpkgs.gnupg nixpkgs.pinentry-curses nixpkgs.pass
# configure pinentry
mkdir -p ~/.gnupg
# Tell GPG where to find pinentry (why is this necessary??)
echo "pinentry-program $(which pinentry-curses)" >> ~/.gnupg/gpg-agent.conf
# kill any gpg agents to reload config
pkill gpg-agent
# still some locale issues, need to set LC_ALL to something UTF-8
LC_ALL=C.UTF-8 pass mypassword
# properly asks for GPG password with pinentry in the terminal
4 Likes