Some useful tips of SSH.
- generate ssh for GitHub/GitLab
ssh-keygen -t ed25519 -C "yourname@mail.com"
in ssh config ($HOME/.ssh/config)
Host username-github.com # ssh -T git@username-github.com
HostName github.com
PubkeyAuthentication yes
IdentityFile ~/.ssh/keys/id_ed25519
Add ssh public key to github/gitlab ssh key in setting.
Add ssh key to macOS keychain
ssh-add --apple-use-keychain ~/.ssh/id_ed25519
Test ssh key
ssh -T git@username-github.com