AndreDurao
AndreDurao

Reputation: 5785

apply cherry pick

I got a simple question for you GIT masters:

in GIT man pages I've got this for

man git-cherry-pick

...
git-cherry-pick - Apply the changes introduced by some existing commits
...

My doubt is: when I cherry-pick a commit to another branch, this commit is moved to the other branch or copied (applied in both branches)?

Upvotes: 1

Views: 292

Answers (1)

ChrisInEdmonton
ChrisInEdmonton

Reputation: 4578

When you cherry-pick from another branch, git applies the patch to the current branch. It leaves the other branch untouched. That is to say, the patch will now be in both branches; the patch is 'copied', not 'moved'.

Upvotes: 5

Related Questions