So imagine an existing code base with files {A, B, C, D, E}. I clone the repo, create a branch, and issue a series of changes
Commit 1 changes files {A, B}
Commit 2 changes files {C, D}
Commit 3 changes files {D, E}
In this example, I need to merge to the parent the files that changed in commit 2, but without any of the changes in Commit 1.
It is my understanding that each commit contains snapshots of the entire code base, as illustrated here:
source
So commit 2 has the changes to files C and D, but it also has the changes to file A and B from commit 1, which should not be merged.
So, how would I merge up the versions of C and D from Commit 2, without changing the parent's version of A and B?