Reputation: 1490
I am a git noob.
My current master branch is 2.1.18. Business requested me to create a new branch from the production version and apply changes and push to production. So I created a branch from the production version which was at 2. 1.10. Made changes and created a pull request Now a get the error
Conflicts prevent automatic merging
How do I merge my current branch which I created from 2.1.10 into master which is 2.1.18 and exclude all the changes from 2.1.10(only include my current changes)- until 2.1.18?
Upvotes: 1
Views: 46
Reputation: 1324347
Business requested me to create a new branch from the production version and apply changes and push to production
If you create a branch from 2.1.10 and not 2.1.18, that means what is running in production is 2.1.10.
So your pull request should not be made against master
, since it is for pushing to production.
That being said, if you need to report your fix against the latest of master
, I would:
master
(and resolve any merge conflict in the context of that rebased branch)That is:
git checkout myFixBranchFrom2.1.10
git checkout -b myFixBranch
git rebase master
Upvotes: 2