mirror of
https://github.com/google/styleguide.git
synced 2024-03-22 13:11:43 +08:00
Project prefix directory should work with Hg.
Patch based on one by tomic80.
This commit is contained in:
parent
7ead64485b
commit
42e59b0ce7
1
cpplint/cpplint.py
vendored
1
cpplint/cpplint.py
vendored
|
@ -719,6 +719,7 @@ class FileInfo:
|
|||
not os.path.exists(os.path.join(root_dir, ".git")) and
|
||||
not os.path.exists(os.path.join(root_dir, ".hg"))):
|
||||
root_dir = os.path.dirname(root_dir)
|
||||
|
||||
if (os.path.exists(os.path.join(root_dir, ".git")) or
|
||||
os.path.exists(os.path.join(root_dir, ".hg"))):
|
||||
prefix = os.path.commonprefix([root_dir, project_dir])
|
||||
|
|
Loading…
Reference in New Issue
Block a user