Re: Git revert cannot be aborted if the repository directory has been copied
On Sun, Nov 3, 2024, at 16:04, Kristoffer Haugsbakk wrote:
Show 16 quoted lines
> On Sun, Nov 3, 2024, at 03:34, Junio C Hamano wrote:
>> Marco Stephan <marc.stephan96@hotmail.de> writes:
>>
>>> If you copy a Git repository directory to another path while there is a revert in progress for the Git repository, "git revert --abort" does not work anymore for the copied repository. Instead, it will report an error of the following format:
>>> error: Entry '...' not uptodate. Cannot merge.
>>> fatal: Could not reset index file to revision '...'.
>>
>> I wonder if
>>
>> $ git update-index --refresh
>>
>> is all it takes.
>
>
> This is correct. This successful test can be added to
> t3501-revert-cherry-pick.sh:
(Meaning one can add it there if one wants to see for themselves)
--
Kristoffer Haugsbakk