0

In Laravel 6 application with git on bitbucket I have several branches and having current branchA I had to switch to branchB and make pull from the git and I run command

git pull  origin  feature/branchB

but seems I missed firstly to run command

git checkout feature/branchB

Now my app raise strange errors

Which is valid way to check current status of branchA with pulling from git and revert to prior state?

Thanks!

mstdmstd
  • 2,195
  • 17
  • 63
  • 140
  • 2
    If the output of `git status` tells you that "Your branch is ahead of 'origin/...' by n commits", that might give you a clue on how many commits you should go back. You could use `git reset --hard HEAD~n` for undoing those commits you pulled, where `n` is the number of commits you want to reset. Just first check your `git log` to see if those are really the commits you want to reset. – acvi Oct 27 '20 at 08:13
  • 2
    Also, this question is more about git (if not exclusively) than it is about Laravel - just a suggestion :) – acvi Oct 27 '20 at 08:14
  • Does this answer your question? [Undo git pull, how to bring repos to old state](https://stackoverflow.com/questions/1223354/undo-git-pull-how-to-bring-repos-to-old-state) – lucidbrot Jan 27 '22 at 20:42

0 Answers0