When Git clone appears, please make sure the correct access rights and the repository exists. The issue has been resolved.

Source: Internet
Author: User
Tags git clone

Read a lot of information finally took care of git in the clone command error This problem, the nonsense is not much to say directly on the steps to be helpful to everyone.

1 Delete the. SSH folder (search this folder directly) under the known_hosts (manually delete, do not need git)

2 in the download good git bin directory open bash.exe input command ssh-keygen-t rsa-c "username" (Note: username for your git username), if the execution succeeds. Return:

generating public/private RSA key pair.
Enter file in which to save the key (/USERS/USERNAME/.SSH/ID_RSA)://Here the username is the user name on the computer, this address is also the storage address of the file, and then we press

Enter if you previously had a storage address that would return/users/your Username/.ssh/id_rsa already exists. Overwrite (y/n) direct input y enter. If there is no previous storage address, it will appear

Enter passphrase (empty for no passphrase), also direct enter, both cases will appear after enter same passphrase again and then enter will display a long list of content where

there are also some. O.. O oo. OS. Code, which means that SSH key has been generated. The file directory is: username/.ssh/id_rsa.pub.

3 then find the system automatically generate two files under the. ssh folder, Id_rsa and Id_rsa.pub, and use Notepad to open id_rsa.pub to copy all the contents .

4 open https://github.com/, login to your account, enter settings (Settings) to find

5 then paste the contents of your copy into the key

Then click Add SSH Key

OK, there's one final step.

6 still enter ssh-t [email protected] in Bash.exe and then jump out of a bunch of content you just enter Yes and you're done, and he'll prompt you to succeed.

Then you can use the git clone command normally, and finally good luck haha!

When Git clone appears, please make sure the correct access rights and the repository exists. The issue has been resolved.

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.