THIS IS FOR GITHUB ONLY!!
If you would like to use ssh, then you will have to set up an ssh key and passphrase for your account.
Check for existing keys
$ ls -al ~/.ssh
Keys will have one of these names:
id_dsa.pub
id_ecdsa.pub
id_ed25519.pub
id_rsa.pub
If you don't have an existing key, generate one with:
$ ssh-keygen -t rsa -b 4096 -C "your_email@example.com"
Enter a file in which to save the key (/Users/you/.ssh/id_rsa): [Press enter]
Enter passphrase (empty for no passphrase): [Type a passphrase]
Enter same passphrase again: [Type passphrase again]
Then add your key to the ssh-agent
$ eval "$(ssh-agent -s)"
Agent pid 59566
$ ssh-add ~/.ssh/id_rsa
Then add your key to GitHub
$ sudo apt-get install xclip
# Downloads and installs xclip. If you don't have `apt-get`, you might need to use another installer (like `yum`)
$ xclip -sel clip < ~/.ssh/id_rsa.pub
# Copies the contents of the id_rsa.pub file to your clipboard
If xclip doesn't work, then just use your favorite text editor to open the file and use your default copy/paste tools to copy the key.
Login to GitHub, click on your profile pic, then click settings. On the right, click SSH and GPG keys. Then click New SSH Key, type in a descriptive title, paste the public key into the key field and submit.
To test your connection, open your Terminal, and type in
ssh -T git@github.com
You should see one of these:
The authenticity of host 'github.com (192.30.252.1)' can't be established.
RSA key fingerprint is 16:27:ac:a5:76:28:2d:36:63:1b:56:4d:eb:df:a6:48.
Are you sure you want to continue connecting (yes/no)?
or
The authenticity of host 'github.com (192.30.252.1)' can't be established.
RSA key fingerprint is SHA256:nThbg6kXUpJWGl7E1IGOCspRomTxdCARLviKw6E5SY8.
Are you sure you want to continue connecting (yes/no)?
Type in yes. Then you should see:
Hi username! You've successfully authenticated, but GitHub does not
provide shell access.
You can now push to GitHub by using your ssh passphrase :)
EDIT: I also use codenvy, this worked perfectly for me. See also this guide: Connecting to GitHub with SSH