How to copy SSH keys to new Mac
0 min

1. Copy your keys from previous machine to same folder on next
Copy your keys from previous machine to same folder on next
On your previous mac
cd .ssh open .
Copy following files to same destinations on new mac
id_rsa - private key id_rsa.pub - public key
2. Add keys to ssh agent on new mac
Create configuration file
touch ~/.ssh/config
with content
Host github.com AddKeysToAgent yes UseKeychain yes IdentityFile ~/.ssh/id_rsa
Add your SSH private hay to ssh-agent
ssh-add --apple-use-keychain ~/.ssh/id_rsa
See more
Read more how to connect to github with ssh on official documentation