Open dashohoxha opened 6 years ago
Few options to implement this:
1) use a custom script for pinentry which changes pinentry to the ones we require based on an environmental variable. refer this 2) use 2 different gpg-agent.conf files for gui and cli and reload gpg-agent with the specific files 3) use something like the method being used by autopin in tests: change the pinentry program line in the gpgagent-conf file (using sed) and reload agent.
PS In all these options we can offer user to specify pinentry-programs for gui and cli in config.sh
On
cmd_init
we set the configuration ofgpg-agent
topinentry-program /usr/bin/pinentry-tty
. Maybe the initialization for the GUI case should be a bit different (for example if we runegpg gui init
instead ofegpg init
). In this case the packagepinentry-gtk2
orpinentry-gnome3
becomes a dependency. Or maybe we can add the configuration of pinentry on Setting, so that the user can choose which one to use.