1

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)?

AndreDurao
  • 5,600
  • 7
  • 41
  • 61

1 Answers1

5

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'.

ChrisInEdmonton
  • 4,470
  • 5
  • 33
  • 48