adding gnupg to dotfiles\n fixes pinentry issues
This commit is contained in:
parent
66cfa7c709
commit
e679f41745
2 changed files with 15 additions and 0 deletions
3
gnupg/.gnupg/gpg-agent.conf
Normal file
3
gnupg/.gnupg/gpg-agent.conf
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
pinentry-program ~/bin/pinentry-smart
|
||||||
|
default-cache-ttl 600
|
||||||
|
max-cache-ttl 7200
|
12
gnupg/bin/pinentry-smart
Executable file
12
gnupg/bin/pinentry-smart
Executable file
|
@ -0,0 +1,12 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
PINENTRY_TUI='/usr/bin/pinentry-curses'
|
||||||
|
PINENTRY_GUI='/usr/bin/pinentry-gnome3'
|
||||||
|
|
||||||
|
if [ -n "${DISPLAY-}" -a -z "${TERM-}" ]; then
|
||||||
|
exec "$PINENTRY_GUI" "$@"
|
||||||
|
else
|
||||||
|
exec "$PINENTRY_TUI" "$@"
|
||||||
|
fi
|
Loading…
Reference in a new issue