The bisection process should check for different versions of your project. If a specific revision does not contain the current folder, then the current folder will be deleted.
In this case, your shell may appear in a folder that is no longer in the file system! Git will not be able to find the top level .git folder, and therefore the bisect process cannot continue without intervention.
Demonstration:
$ git rev-parse --show-toplevel /path/to/project $ mkdir tmp $ cd tmp $ rmdir ../tmp $ git rev-parse --show-toplevel fatal: Unable to read current working directory: No such file or directory
Of course, the same problem can occur when doing git checkout , and it can be easily fixed after the fact, for example. with cd .. (willoller explains why this works in the shell but not in git).
But since deactivation is a process, it makes sense to avoid this situation before we start, especially if we want to use automation like git bisect run .
joeytwiddle Aug 15 '16 at 2:06 on 2016-08-15 02:06
source share