Answer the question
In order to leave comments, you need to log in
Why does git cherry-pick copy the entire branch when copying a commit?
Hello!
When studying git, I encountered a misunderstanding of how it should work in case of copying branches.
There are rumors that cherry-pick takes git diff -U0 feature^ HEAD and copies it to HEAD, but I didn't succeed.
Here is a list of my commits:
Answer the question
In order to leave comments, you need to log in
OK. There was a conflict. But why?
1. Am I misunderstanding how this command should work, or did something go wrong here?
3. If cherry-pick works the same way as merge, then maybe it's better to do for copying squash?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question