Skip to content

Commit

Permalink
fix(rag_service): ignore leading slash gitignore patterns
Browse files Browse the repository at this point in the history
  • Loading branch information
joaoinez committed Feb 26, 2025
1 parent 9c9fadd commit a47b850
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion py/rag-service/src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -528,7 +528,7 @@ def scan_directory(directory: Path) -> list[str]:
if not spec:
matched_files.extend(file_paths)
continue
matched_files.extend([file for file in file_paths if not spec.match_file(file)])
matched_files.extend([file for file in file_paths if not spec.match_file(os.path.relpath(file, directory))])

return matched_files

Expand Down

0 comments on commit a47b850

Please sign in to comment.