git push -u origin master error report
PHPz
PHPz 2017-05-31 10:35:46
0
3
1429

There is a project locally. I first git init to initialize the library, and then git add.
git commit -m"test"
Configuration association
git remote add origin git@github.com:myName/test .git

Execution Upload to the good library I have created on github,
The command reports an error, failed to push some refs to git@github.com:myName/test.git

After Baidu, it said that I need to bring the README.md file. I created this file locally, but still get an error?
What’s your reason?

After using git pull --rebase origin master, many characters will be inserted into the code. . . . .

How do you deal with this problem? . .

Execute git pull origin master

PHPz
PHPz

学习是最好的投资!

reply all(3)
淡淡烟草味

Reason

1. The server warehouse is not clean when it is created, so you need to drag it down from the server first

Solution

1.

$git pull origin master
//你自己建了readme可能会要求你merge
$git push origin master

//If you built the readme yourself, you may be asked to merge it, please merge it manually

phpcn_u1582

It means that the branch you submitted is still behind the online branch, which means that the local and online versions are not unified
Let me tell you the solution
Don’t git init
You should first git clonethe remote warehouse
and then Perform the following operations.

迷茫

The answer has been given in the prompt,

git pull
git add -A
git commit -m '合并冲突'
git push
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template