Add SSH for Github

Source: Internet
Author: User

Add SSH for Github

This is just a Linux cainiao diary, which is concise and realistic. It records the process of adding ssh to Github in OSX for code blindness.

Clone the source code from Github to the local machine and find that there is no ssh password secret.

Therefore, go to the official website to help show pictures and tigers as follows:

1. Open shell and type

ls -al ~/.ssh

2. If there is a correct. pub in the echo that exists in rsa, you can skip it down.

3. Otherwise, create a new

Ssh-keygen-t rsa-B 4096-C "your Email account"

(Case sensitive, the last C is case sensitive). Echo too into argument is generally case sensitive.

3. Echo

Enter file in which to save the key

Enter the directory to be placed and press Enter.

4. Echo

Enter passphrase

5. Enter the password and press Enter.

6. Repeat the password and press Enter.

7. Echo

SHA256: DkDGfbid94Li7Lt2hfaC87VnBl09vLlJcH1ubtvHlj Ru's mailbox The key's randomart image is: + --- [RSA 4096] ---- + |. o .. | o .. |. + .... | .. o... ++ |. S + o. o. = |. o + o | o +. o. o. + = | * o... + EO | o + *... ++ = | + ---- [SHA256] ----- +

8. confirm that the ssh proxy is in the enabling status. If yes, the pid is returned.

eval "$(ssh-agent -s)"

9. Add the obtained key to ssh

ssh-add ~/.ssh/id_rsa

10. Copy the key to the clipboard.

pbcopy < ~/.ssh/id_rsa.pub

11. I pasted the key to the dash and used it for backup. There is no security risk in all aspects.

Then, log on to github and paste the key.

You may also like the following SSH-related articles. For details, refer:

Complete SSH service configuration and troubleshooting in Ubuntu

How to install Samba and SSH server in Ubuntu 14.04

SSH service remote access to Linux Server login is slow

How to Improve the SSH login authentication speed of Ubuntu

Enable the SSH service to allow Android phones to remotely access Ubuntu 14.04

How to add dual authentication for SSH in Linux

Configure the SFTP environment for non-SSH users in Linux

Configure and manage the SSH service on Linux

This article permanently updates the link address:

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.