1. Generate a key on your computer
ssh-keygen-t rsa-c "[email protected]"
2, two files Id_rsa and id_rsa.pub are generated in the ~/.ssh directory in the Ubuntu system. The private key is saved in Id_rsa, and the public key is saved in Id_rsa.pub.
3, open id_rsa.pub, in Gitlab add key to the copied content can be added
Error encountered: Fingerprint cannot be generated translation: Fingerprint cannot be generated
error Reason: Because the VIM editor has set NUM, set Nonu, full-screen copy, the problem is solved
possible cause of error: Whether your e-mail address is at the end of your public key
4. Modify remote repository address to SSH address
git remote set-url origin git address
5,pull and push require a password solution
When you think that all the problems are resolved, you need a password when you use Git.
Workaround: Enter Ssh-add carriage return to resolve
To be continued
http://segmentfault.com/q/1010000000835302/a-1020000000883441
SSH Free Login problem
A very small git use SSH protocol, encounter so many problems, later encounter is not afraid!
Gitlab Configuring SSH && Ubuntu