I had a feature branch and that I needed to merge into master so I created a pull request through github and merge it.
I was expecting that all changes in feature brach that were different from master will overwrite that particular file in master but after the merge I noticed the opposite that feature branch got updated with the code (the one which was different in master) and master file remained same.
Please correct my understanding if I am wrong. When we merge brach A into branch B, branch A should not get changed. isn't it ?
Thanks,
I’m guessing you ran
git merge master. This merged master into the current branch.To merge the feature branch into master, you need to switch to the master branch, and then run
git merge feature. That being said, you can create a PR without merging feature into master.