1

I was on master branch and unfortunately, I run the command git pull origin DEV13-ConsumerReport-20190827 which is created from master, it merged into master automatically. The branch DEV13-ConsumerReport-20190827 was not stable at that time. then I run command to revert back to Head. after that master was stabled. after working on DEV13-ConsumerReport-20190827 when I want to merge it into master, it was not merged properly. I repeat the process again, I revert to Head in the master branch, then I again merge DEV13-ConsumerReport-20190827 into master. the status shows already updated. but code was mashed up and not merge properly.

Any kind of help will be appreciated.

4
  • 1
    This sounds like a duplicate: stackoverflow.com/questions/41516743/… Commented Sep 1, 2019 at 9:54
  • Thanks, @JohnSzakmeister. I got solution by running this command. git reset --hard origin/master Commented Sep 2, 2019 at 11:01
  • Be careful with that... if you're sharing the repo with others, then you could be setting yourself up for a mess of a problem to clean up. The better way would be to "revert the revert". It avoids modifying history on other users, which is a big plus when working with others. Commented Sep 2, 2019 at 13:14
  • Ok, got it @JohnSzakmeister Thanks Commented Sep 5, 2019 at 11:19

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.