0
I’m trying to make a git push
, but this error always arises:
$ git push
fatal: The current branch master has no upstream branch.
To push the current branch and set the remote as upstream, use
git push --set-upstream origin master
dell latitude@DESKTOP-KU6NT53 MINGW64 ~/Downloads/hellospringboot (master)
$ git push --set-upstream origin master
To https://github.com/LealVinicius/arqdesint.git
! [rejected] master -> master (fetch first)
error: failed to push some refs to 'https://github.com/LealVinicius/arqdesint.git'
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
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.
Updates were rejected because the remote contains work that you do not have locally
What the above error is saying is that you don’t have in your local repository the latest changes that were received in your remote repository on Github. Generally, just rungit pull origin master
before doing thepush
again.– pauloimon