tunnckoCore / x-dotfiles

Maintained, latest as of Q4 2018. Much updates compared to the `arckos` repo.
MIT License
1 stars 0 forks source link

configs #3

Open tunnckoCore opened 5 years ago

tunnckoCore commented 5 years ago

the ~/.ssh/config

Host *
  IgnoreUnknown AddKeysToAgent,UseKeychain
  AddKeysToAgent yes
  UseKeychain yes
  User git
  IdentityFile ~/.ssh/id_rsa

and the keychain (the Funtoo program, v2.8.2), which handles both SSH and GPG agents.

Put it on .bashrc, .zshrc, .zprofile or .profile - it depents

# 422000 = 5 days
# after the flags, put your SSH private key(s) file 
# and/or GPG key ID(s)
eval `keychain --agents gpg,ssh --dir ~/.keychain --timeout 432000 --quiet --eval --nogui ~/.ssh/id_rsa 5E2BC183638774D3`

for some bugs we need ~/.gnupg/gpg.conf to be

keyid-format LONG

and the gpg agent config, at ~/.gnupg/gpg-agent.conf

pinentry-timeout 0
pinentry-program /usr/bin/pinentry-curses
default-cache-ttl 432000
max-cache-ttl 432000

# if below GnuPG < 2.1
# maximum-cache-ttl 432000