Git Cherry Pick – Transfer commits From One Branch to Another

Git Cherry Pick – Transfer commits From One Branch to Another

Notes on a practical example for cherry-pick commits from one git branch and push to another git branch.

Open Two terminals

Terminal one : see loglines from for branch – A : git log –oneline

Terminal Two : Create a new Branch -B, and Cherry Pick commits from branch-A

git checkout -b ZUI-146-1
git cherry-pick eff3e9e2
git cherry-pick 94ad5d60
git cherry-pick 0515a3c5
git cherry-pick 58eda68c
git cherry-pick 7e850dfe
git cherry-pick cf3f4cc7
git push –set-upstream origin ZUI-146-1

Cherry Pick Transfer commits from one Branch to Another

To cancel the cherry-pick operation on Conflict

You are currently cherry-picking commit d386e714f.
(all conflicts fixed: run “git cherry-pick –continue”)
(use “git cherry-pick –abort” to cancel the cherry-pick operation)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s