(It's the first time I'm trying to use git's cherry picking, so maybe I misunderstood what it is or what it can do)
While working on some new feature in a feature branch (for simplicity let's call it just next
), I discovered some bugs in the current master
that I fixed "on the fly" (which may not have been the best idea). Now that I think the feature branch is complete, I'd like to cherry pick some or all of the bugs fixed in next
to master
to make a bug-fix release before a feature release.
So I checked out master
and tried (after reading the git-cherry manual page):
git cherry
git cherry next
git cherry -v next
git cherry -v next master
However none of the commands did output anything, even though there is a huge difference between next
and master
.
So what is the problem? Did I do something wrong, or did I misunderstand about cherry picking? The manual refers to some "origin" branch, while my branch is local.
If the cherry picking is the wrong tool, what would be the correct procedure to achieve what I'm trying to do?