Setting Up SSH and Github

Navigation: Instructions

Instructions

Generate an SSH keypair.

$ ssh-keygen -t rsa -b 4096 -C "your_email@example"

Hit Enter to select a default location. Enter a password if you like. Then, start the SSH agent and add the private key.

$ eval "$(ssh-agent -s)"
$ ssh-add ~/.ssh/id_rsa

Copy your public key.

$ cat ~/.ssh/id_rsa.pub

In your GitHub account, go to Settings, then "SSH and GPG Keys". Click "New SSH Key" and paste your key in. Now you are able to clone repositories from GitHub with SSH.

Sources

GeeksForGeeks: How to Use HTTPS or SSH for git?