I just came into contact with git. I configured sublime text3 according to the steps on the Internet, and then went to git push origin master. An error was reported at this step, so I used the method provided by the blogger and executed git pull origin master first, but I got an error and could not read the remote warehouse. , please give me some advice.
1. The error is reported as shown in the figure
I checked some information, added the key for the Permission denied error, and then re-ran git pull origin master
As shown in the figure:
When running push
I still get an error here, I don’t quite understand it, please give me some advice
After searching for information, I finally uploaded it successfully
Solution:
Error about pull: refusing to merge...
Because they are two different projects, to merge two different projects, git needs to add a line of code , in git pull, so
git pull origin master --allow-unrelated-histories
and then push is ok
git push origin master
First you need to bind it to the remote warehouse
Remember to change it to your warehouse name.
If it is the first time to submit to the remote warehouse
If it’s not your first time, just use it
You can push
About using git, you can read my blog
Basic git operations
git usage tutorial and experience
github usage tutorial (1)
github usage tutorial (2)
github usage tutorial (3)
github usage tutorial (4)
Personal blog