From 01e3327112ca6217ce591d8bcc67477b7bc686fe Mon Sep 17 00:00:00 2001 From: shuofengzhang Date: Sun, 8 Mar 2026 17:56:21 +0800 Subject: [PATCH] fix: use non-deprecated pathspec gitignore parser Signed-off-by: shuofengzhang --- pyproject.toml | 2 +- src/claudesync/utils.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 46f74b5f2..786484373 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "claudesync" -version = "0.7.6" +version = "0.7.7" authors = [ {name = "Jahziah Wagner", email = "540380+jahwag@users.noreply.github.com"}, ] diff --git a/src/claudesync/utils.py b/src/claudesync/utils.py index c8a8eda3f..f53c57c5a 100644 --- a/src/claudesync/utils.py +++ b/src/claudesync/utils.py @@ -51,7 +51,7 @@ def load_gitignore(base_path): gitignore_path = os.path.join(base_path, ".gitignore") if os.path.exists(gitignore_path): with open(gitignore_path, "r") as f: - return pathspec.PathSpec.from_lines("gitwildmatch", f) + return pathspec.PathSpec.from_lines("gitignore", f) return None @@ -201,7 +201,7 @@ def get_local_files(config, local_path, category=None, include_submodules=False) if category: patterns = categories[category]["patterns"] - spec = pathspec.PathSpec.from_lines("gitwildmatch", patterns) + spec = pathspec.PathSpec.from_lines("gitignore", patterns) submodules = config.get("submodules", []) submodule_paths = [sm["relative_path"] for sm in submodules] @@ -366,7 +366,7 @@ def load_claudeignore(base_path): claudeignore_path = os.path.join(base_path, ".claudeignore") if os.path.exists(claudeignore_path): with open(claudeignore_path, "r") as f: - return pathspec.PathSpec.from_lines("gitwildmatch", f) + return pathspec.PathSpec.from_lines("gitignore", f) return None