mirror of
https://github.com/tiennm99/serena.git
synced 2026-10-13 00:15:05 +00:00
fix: discover all .gitignore files in project
Before this change only `.gitignore` files at the project root and its direct subdirectories where found.
This commit is contained in:
1 parent
b8daef9167
commit
cffbb81036
1 file changed
+2
-1
@@ -141,7 +141,8 @@ class GitignoreParser:
|
||||
|
||||
:return: List of absolute paths to .gitignore files
|
||||
"""
|
||||
return glob.glob(self.repo_root + "/.gitignore") + glob.glob(self.repo_root + "/**/.gitignore")
|
||||
relative_paths = glob.glob("**/.gitignore", root_dir=self.repo_root, recursive=True)
|
||||
return [os.path.join(self.repo_root, rel_path) for rel_path in relative_paths]
|
||||
|
||||
def _create_ignore_spec(self, gitignore_file_path: str) -> GitignoreSpec:
|
||||
"""
|
||||
|
||||
Reference in new issue
Block a user