For the git commit has been very cautious, feel accidentally will step on the inexplicable pit.
It's not,
One day commit encounters the on branch master nothing to commit (working directory clean)
A look at the meaning. Is your branch clean?
Clean? Excuse me?
Then GIT push Origin master, a long wait for the pop-up fail:#¥%@ (omitted here, we value points)
Please make sure the correct access rights and the repository exists.
Then Google a bit, the original is SSH key has a problem, not connected to the server ~ ~
And then I started a dead end.
See a lot of answers, found that the writing is not very complete, their own east groping West groping done, afraid to forget, record
1, first I have to re-set the identity of the name and mailbox in Git (because I forgot to set what, because of the hole) into the folder to be submitted (because directly open git Bash, in the absence of a path, there is no!). Method! Change! The pit that I encountered when I first used git ... )
git config--global user.name "yourname"
git config--global user.email "[Email protected]"
Note: yourname is the name you want to set, [email protected] is the mailbox you want to set up.
2. Delete the. SSH folder (search for this folder directly) under the known_hosts (manually delete, do not need git)
3. Git input command
$ ssh-keygen-t rsa-c "[Email protected]" (please fill in the email address you set)
Then appears:
Generating public/private RSA key pair.
Enter file in which to save the key (/USERS/YOUR_USER_DIRECTORY/.SSH/ID_RSA):
Please press ENTER directly
Then the system will automatically generate two files under the. ssh folder, Id_rsa and Id_rsa.pub, with Notepad open id_rsa.pub
Copy all of your content
4. Open https://github.com/, login to your account, enter settings
Enter SSH settings
Paste the copy that you just copied in key
Click Add SSH Key,
Ok!
5. Enter the command in git:
ssh-t [email protected]
And then it jumps out a bunch of words.
Input command: Yes
Enter
Then you will be prompted to succeed.
Tears Cow Face ~ ~
Finally quit git to re-enter the path to submit it again ~ ~
Reproduced----51892864
The problem with Git is "make sure the correct access rights and the repository exists."