Reputation: 502
How do i create a merge request form 1 commit only and ignore the previous commit?
git commit -m
Upvotes: 1
Views: 91
Reputation: 56
Pulling in changes for a single commit is called a cherry-pick in git. A merge is merging two independent streams of development, typically with common history, into one "merged" stream. This implicitly includes the entire history of the branch.
The way you can get what you are after though, is to create a new branch from the commit before the commit you do not want to include. Then cherry-pick the commit you do want into your new branch. Now you have a fresh branch with just the items you want to include, and that is the branch you initiate the merge request with.
Upvotes: 2