Skip to content

Commit 09416d0

Browse files
authored
Use GitIgnoreSpec in ts_utils.get_gitignore_spec (#13797)
1 parent 2b7019b commit 09416d0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/ts_utils/utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ def allowlists(distribution_name: str) -> list[str]:
204204
@functools.cache
205205
def get_gitignore_spec() -> pathspec.PathSpec:
206206
with open(".gitignore", encoding="UTF-8") as f:
207-
return pathspec.PathSpec.from_lines("gitwildmatch", f.readlines())
207+
return pathspec.GitIgnoreSpec.from_lines(f)
208208

209209

210210
def spec_matches_path(spec: pathspec.PathSpec, path: Path) -> bool:

0 commit comments

Comments
 (0)