git提交时报错:Updates were rejected because the tip of your current branch is behind:
There are several solutions:
1. The use of push force:
git push -u origin master -f
It would be modified remotely loss is generally not advisable, especially when many people work together to develop.
2.push remote repository before the first modified pull down
git pull origin master git push -u origin master
3. If you do not want to merge remote and local changes, you can create a new branch:
git branch [name] 然后push git push -u origin [name]