diff options
author | Benjamin Morrison <ben@gbmor.org> | 2022-10-15 02:38:38 -0400 |
---|---|---|
committer | Benjamin Morrison <ben@gbmor.org> | 2022-10-15 02:40:45 -0400 |
commit | e53c78eedff7d6b51cb824f92671a73a7411d1f2 (patch) | |
tree | d80d245bae3846960df79a5460a188568d748c26 /bin/gk | |
parent | 705b3c4c6ed218a1000ce8009ba0970885f20022 (diff) | |
download | dogfiles-e53c78eedff7d6b51cb824f92671a73a7411d1f2.tar.gz |
update git, gpg, neomutt confs for new gpg key.
add line to gk to make it easier to switch yubikeys.
Diffstat (limited to 'bin/gk')
-rwxr-xr-x | bin/gk | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/bin/gk b/bin/gk index a25edf8..942a890 100755 --- a/bin/gk +++ b/bin/gk @@ -1,9 +1,16 @@ #!/bin/sh + +PARAM="$1" + pkill -9 gpg-agent export GPG_TTY=$(tty) export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket) -gpg-connect-agent updatestartuptty /bye +if [ "$PARAM" = "switch" ]; then + gpg-connect-agent "scd serialno" "learn --force" /bye +fi + +gpg-connect-agent updatestartuptty /bye gpgconf --create-socketdir |