his error reported when using webstorm or idea push code
The reason is to manually create git and specify the remote project
Open Terminal
git init # Initialize the local warehouse
git remote -v # View the associated warehouse address
git remote add origin https://gitee.com/xjseo/personnel-management.git # Add remote warehouse address
Then restart the editor and it will appear in the upper right corner
Then click the checkmark commit to submit all the code to the temporary storage,
Then click the third arrow to push
Will be fail to push
Checking the git log will find the following errors:
error: failed to push some refs to 'https://gitee.com/xjseo/personnel-management.git'
hint: Updates were rejected because the remote contains work that you do
To https://gitee.com/xjseo/personnel-management.git
hint: not have locally. This is usually caused by another repository pushing
! refs/heads/master:refs/heads/master [rejected] (fetch first)
Done
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
The general idea is that you should pull the warehouse code and synchronize the local code.
So then click the first one to pull the following and then click the third push to succeed.
Read More:
- Git Push Error: error: failed to push some refs… hint: Updates were rejected because the remote…
- [Solved] Git submits locally to the remote warehouse Error: failed to push some refs to…
- Local repository upload to remote repository error: failed to push some refs to ‘https://hub.fastgit.org/zhizhangxuezhang/ui-test.git‘
- Keras’ print model error: Failed to import pydot. You must install pydot and graphviz for `pydotprint` to work.
- Git Push Error: failed to push some refs to ‘[email protected]:
- [Solved] error TS2584: Cannot find name ‘console’. Do you need to change your target library? Try changing the ‘lib’ compiler option to include ‘dom’.
- Git push Submit to Remote Error: “remote: Support for password authentication was removed on August 13, 2021.“
- How to Fix Error Cannot find command ‘git‘ – do you have ‘git‘ installed and in your PATH?
- [Solved] Remote URL test failed: Could not read from remote repository.
- [Solved] Could not resolve placeholder ‘XXX‘ in value “${XXX}“
- Cordova – CordovaError: Promise rejected with non-error: ‘ios-deploy was not found
- [Solved] Git Push Error: &fatal: the remote end hung up unexpectedly
- Proguard Packaging Error: You have to specify ‘-keep‘ options if you want to write out kept elements with ‘-print
- Error c4996: ‘getversionexa’: declared rejected [How to Solve]
- [Solved] Eslint error: /xxx/components/xxx import should occur after import of /xxx/utils/xxx
- Gitlab nginx wont start to work. [down: nginx: 1s, normally up, want up; run: log: (pid 20128)xxx]
- How to Solve Git Error: error: failed to push some refs to……
- [Solved] error C4996: QString::SkipEmptyParts declaration has been rejected
- [Solved] error: Pulling is not possible because you have unmerged files
- error: src refspec master does not match any. [How to Solve]