My situation:
I'm coding on a project, called project
, now it's half-done.
But at this moment, I'm asked for another project, called project-cn
, 80% same as project
, but there are still different features to be develop.
My solution for now:
- new branch
master-cn
frommaster
branch ofproject
; - develop the unique features of
project-cn
undermaster-cn
; - checkout back to
master
branch, develop new common feature of both; - Manual copy the new feature modify to the
master-cn
.
My expectations:
project-hk
/ \
/ \
master master-cn
/ \
/ \
add feature-hk-1 add feature-cn-1
| |
| |
add feature-hk-2 add feature-cn-2
| |
| |
| feature-both |
| / \ |
|merge/ \merge|
| / \ |
| / \ |
| / \ |
| / \ |
master master-cn
My Question:
What should I do ? And where is the feature-both
from ? A new branch ? Base on where?