My directory structure is like this:
- Code: Select all
[Branch A] [Branch B]
| |
+--Dir1 +--Dir1
+--Dir2 +--Dir2
| | |
+--DirA | +--DirA
| | |
+--File1 | +--File1
+--File2 | +--File2
| +--File3
| +--File4
+--Dir3
I want to merge Branch B/Dir2/DirA into Branch A/Dir2/DirA. I want File1 and File2 to be merged and File3 and File4 should be created in Branch A. I don't want to pick up Dir3, or any changes in Dir1.
I've tried the steps outlined by kernel.org for merging subtrees, but they fail when I do the git read-tree with:
- Code: Select all
error: Entry 'Dir1/DirA/File1' overlaps with 'Dir1/DirA/File1'. Cannot bind.
I could cherrypick the files to merge, but that seems unnecessarily convoluted for what should be a common and straight-forward problem.
Thanks,
Annirak
