Bug 1313446 - Detect a git repository when inside a git worktree. r=glandium
MozReview-Commit-ID: 8ngY6kNcp05
This commit is contained in:
@@ -99,7 +99,7 @@ def get_repository_object(path):
|
|||||||
'''
|
'''
|
||||||
if os.path.isdir(os.path.join(path, '.hg')):
|
if os.path.isdir(os.path.join(path, '.hg')):
|
||||||
return HgRepository(path)
|
return HgRepository(path)
|
||||||
elif os.path.isdir(os.path.join(path, '.git')):
|
elif os.path.exists(os.path.join(path, '.git')):
|
||||||
return GitRepository(path)
|
return GitRepository(path)
|
||||||
else:
|
else:
|
||||||
raise Exception('Unknown VCS, or not a source checkout: %s' % path)
|
raise Exception('Unknown VCS, or not a source checkout: %s' % path)
|
||||||
|
|||||||
Reference in New Issue
Block a user