When I am in the middle of a rebase
conflict, I'd like to see the changes that would be instituted by --ours
, --theirs
and HEAD
.
So, I check out all of them (literally):
git checkout --ours <new_file>
vim <new_file>
...I examine the file...
git checkout --theirs <new_file>
vim <new_file>
...I examine the file...
git checkout HEAD <new_file>
vim <new_file>
...I examine the file...
Then, I go back and checkout theirs
and ours
:
git checkout --theirs <new-file>
vim <new-file>
For some reason, --theirs
and --ours
have both conformed to the version when I checked out HEAD
. I understand the git checkout
is supposed to change the working directory and the index, but even when I checkout --theirs
again it is still like the HEAD
version.
How/why is this? And is there a way to get back my original --theirs
and --ours
versions? Thanks.