Skip to content

Commit 74e503f

Browse files
authored
fix: gitignore and gitingestignore files are now correctly processed … (#416)
1 parent 11e2fce commit 74e503f

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/gitingest/entrypoint.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,15 +83,14 @@ async def ingest_async(
8383
token=token,
8484
)
8585

86-
if not include_gitignored:
87-
_apply_gitignores(query)
88-
8986
if query.url:
9087
_override_branch_and_tag(query, branch=branch, tag=tag)
9188

9289
query.include_submodules = include_submodules
9390

9491
async with _clone_repo_if_remote(query, token=token):
92+
if not include_gitignored:
93+
_apply_gitignores(query)
9594
summary, tree, content = ingest_query(query)
9695
await _write_output(tree, content=content, target=output)
9796
return summary, tree, content

src/gitingest/utils/ignore_patterns.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,6 @@ def load_ignore_patterns(root: Path, filename: str) -> set[str]:
194194
for ignore_file in root.rglob(filename):
195195
if ignore_file.is_file():
196196
patterns.update(_parse_ignore_file(ignore_file, root))
197-
198197
return patterns
199198

200199

0 commit comments

Comments
 (0)