mirror of
https://github.com/shokinn/.files.git
synced 2025-06-28 15:50:41 +00:00
add gpg agent config fot tty passphrase entry
This commit is contained in:
parent
f05cc4561e
commit
ef7339743e
3 changed files with 19 additions and 6 deletions
|
@ -30,14 +30,18 @@ if [ $? -ne 0 ]; then
|
|||
(setsid nohup socat UNIX-LISTEN:$SSH_AUTH_SOCK,fork EXEC:{{@@ env['HOME'] @@}}/.ssh/wsl2-ssh-pageant.exe >/dev/null 2>&1 &)
|
||||
fi
|
||||
|
||||
# Currently not used
|
||||
# Connect to windows gpg agent
|
||||
# https://github.com/BlackReloaded/wsl2-ssh-pageant
|
||||
export GPG_AGENT_SOCK={{@@ env['HOME'] @@}}/.gnupg/S.gpg-agent
|
||||
ss -a | grep -q $GPG_AGENT_SOCK
|
||||
if [ $? -ne 0 ]; then
|
||||
rm -rf $GPG_AGENT_SOCK
|
||||
(setsid nohup socat UNIX-LISTEN:$GPG_AGENT_SOCK,fork EXEC:"{{@@ env['HOME'] @@}}/.ssh/wsl2-ssh-pageant.exe --gpg S.gpg-agent" >/dev/null 2>&1 &)
|
||||
fi
|
||||
# export GPG_AGENT_SOCK={{@@ env['HOME'] @@}}/.gnupg/S.gpg-agent
|
||||
# ss -a | grep -q $GPG_AGENT_SOCK
|
||||
# if [ $? -ne 0 ]; then
|
||||
# rm -rf $GPG_AGENT_SOCK
|
||||
# (setsid nohup socat UNIX-LISTEN:$GPG_AGENT_SOCK,fork EXEC:"{{@@ env['HOME'] @@}}/.ssh/wsl2-ssh-pageant.exe --gpg S.gpg-agent" >/dev/null 2>&1 &)
|
||||
# fi
|
||||
|
||||
# Set GPG_TTY to enable passphrase entry via tty
|
||||
export GPG_TTY=$(tty)
|
||||
|
||||
# X410 (Windows X11 Server)
|
||||
export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2; exit;}'):0.0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue