The solution is as follows:
1. Switch to the directory where your project is located, right-click to select git bash here, ALT + F12
can be used in idea
2. In the terminl window, enter the command in turn:
2
git pull
git pull origin master
git pull origin master –allow-unrelated-histories
3. Push your project again in idea, success
If not: git push – U origin master – F
Similar Posts:
- Git | fatal: refusing to merge unrelated histories [How to Solve]
- Git push Updates were rejected because the tip of your current branch is behind
- fatal: refusing to merge unrelated histories [How to Solve]
- [Solved] Git pull fatal: refusing to merge unrelated histories
- Solving git reusing to merge unrelated histories
- How to Solve error: failed to push some refs to ‘xxxx’
- Git error: setting certificate verify locations [How to Solve]