I am working on a project with a Master branch, of course :P and multiple release branches created over time. The version control I'm using is Git and I was looking for a way to apply bug fixes (for example) made in one release branch to the others, automatically if possible. I.e...
--------------------------Master
| | |__v3
| |__v2
|___v1
|____bugfix
If I fix a bug found in v1, and need to apply the same fix (and only the fix) in v2 and v3, is there a way I can do this conveniently in Git?
I am new to Git but thought I might be able to Chery-pick the commit and apply it, but I was wondering if the branches need to be directly related in the hierarchy? Is it possible to cherry-pick or perhaps rebase from 'bugfix' under v1 to v2 and v3? (or v3 to v2 etc) Afaik, rebase will replay all commits, so I think cherry-pick is what im looking for, but I am unsure how to achieve this. Posts I have seen cherry-pick from child to parent branch. Is what im trying to do possible?
Cheers.