I wan to use a reverted history commit.
Let's say this is my commit tree
A -> A' -> B -> C -> D
I made a commit A
and reverted it by A'
. Now, I am at D
and I want my commit tree to be like
A -> A' -> B -> C -> D -> A''
, where A''
is as same as A
.
To summarize, I want to use a history commit.
I cannot simply checkout to A
because I hope B, C, D
be included.
I tried git cherry-pick
, but B, C
have conflicts with A
.
My question is: How should I use cherry-pick
to transform my commit tree to A -> A' -> B -> C -> D -> A''
, without solving conflicts manually? (I tried git cherry-pick -X ours
and git cherry-pick cd003861 --strategy-option theirs
but failed.)