Reputation: 6360
I'm confused about this situation.
I basically develop alone, but sometime my teammate add some feature.
So I made a develop branch.(It's still beta phase, so I don't want to merge add-subscripiton
branch to develop
.)
I'd love to make 'develop' branch catch up withadd-subscription
branch.
I could do something like
git checkout develop
git rebase add-subscription
However this messes the history up. How can I work around?
Upvotes: 1
Views: 1210
Reputation: 3174
If you want all commits of add-subscription
in develop
you can do
git checkout develop
git merge add-subscription
which keeps develop
up-to-date with add-subscription
but leaves add-subscription
untouched.
If you only want certain (but not all) commits from add-subscription
in develop
you can use
git checkout develop
git cherry-pick <commit>...
Both methods (in contrast to rebase
) do not change history.
Upvotes: 1