-3

I have just ran git merge master on my local branch, resolved the conflicts that it was presenting.

However, git will now no longer allow me to commit to my branch using git push. I have just ran git pull and have been met with this feedback:

    There is no tracking information for the current branch.
    Please specify which branch you want to merge with.
    See git-pull(1) for details.

    git pull <remote> <branch>

If you wish to set tracking information for this branch you can do so with:

    git branch --set-upstream-to=<remote>/<branch> 4318-niall-activities

I don't want to over right my current work but I want to submit a Pull request with all my current work. Can anyone offer some advice?

4
  • does 4318-niall-activities exist on the remote repository and have you previously pushed this branch to it?
    – castis
    Apr 6, 2018 at 18:26
  • @castis Yes, I have been using it all day, but since I have merged master into the branch, it will not allow me to push to git Apr 6, 2018 at 18:30
  • What don't you understand about the error message?
    – jhpratt
    Apr 6, 2018 at 18:31
  • @jhpratt will git pull 4318-niall-activities over right my work on my local branch? Apr 6, 2018 at 18:33

1 Answer 1

0

As the error message is pointing out, your local branches are not linked to a remote repository. You can do git push origin [remotebranch] or use git branch --set-upstream-to=<remote>/<branch> 4318-niall-activities to be able to push or pull again, replacing remote and branch with your use case. Remote being origin usually

2
  • git push origin 4318-niall-activities gave back: error: failed to push some refs to 'https://github.com/comediadesign/nec-phase-1.git' hint: Updates were rejected because the tip of your current branch is behind hint: its remote counterpart. Integrate the remote changes (e.g. hint: 'git pull ...') before pushing again. hint: See the 'Note about fast-forwards' in 'git push --help' for details. Apr 6, 2018 at 18:32
  • 1
    then do git pull origin 4318-niall-activities , it will merge remote changes into your local work. Won't erase your work Apr 6, 2018 at 18:35

Not the answer you're looking for? Browse other questions tagged or ask your own question.