This commit is contained in:
linkliti 2026-05-14 08:44:22 +08:00 committed by GitHub
commit f8a27dd8bc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 5 additions and 5 deletions

View file

@ -261,7 +261,7 @@ class BackupService:
processed_count = 0
try:
spec = PathSpec.from_lines("gitwildmatch", pattern_lines)
spec = PathSpec.from_lines("gitignore", pattern_lines)
# Walk through base directories
for base_pattern_path, base_real_path in self.base_paths.items():
@ -507,7 +507,7 @@ class BackupService:
if pattern_lines:
from pathspec import PathSpec
restore_spec = PathSpec.from_lines("gitwildmatch", pattern_lines)
restore_spec = PathSpec.from_lines("gitignore", pattern_lines)
# Process each file in archive
for archive_path in archive_files:
@ -663,7 +663,7 @@ class BackupService:
if pattern_lines:
from pathspec import PathSpec
restore_spec = PathSpec.from_lines("gitwildmatch", pattern_lines)
restore_spec = PathSpec.from_lines("gitignore", pattern_lines)
# Process each file in archive
for archive_path in archive_files:

View file

@ -502,7 +502,7 @@ def _resolve_ignore_patterns(ignore: str | None, root_abs_path: str) -> Optional
if not lines:
return None
return PathSpec.from_lines("gitwildmatch", lines)
return PathSpec.from_lines("gitignore", lines)
def _list_directory_children(

View file

@ -131,7 +131,7 @@ def _build_ignore_spec(gitignore: str) -> PathSpec | None:
]
if not lines:
return None
return PathSpec.from_lines("gitwildmatch", lines)
return PathSpec.from_lines("gitignore", lines)
def _find_matching_files(