Skip to content
Commit e52f29dd authored by Jacob Bramley's avatar Jacob Bramley
Browse files

Use a more robust method to look for the Git root.

In particular, checking for a directory named '.git' fails when 'git-worktree'
is used, since worktrees get a file named '.git', not a directory.

Conveniently, Git commands in worktrees behave superficially as if the worktree
is itself a normal Git repository, so we can simply ask Git for the top level
directory and compare it with the provided path.

Change-Id: I41ef4667ae7121b304b03f8c39ec4c700d1f1c4e
parent 44096c4d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment