From 2e67a01734c104d4da4ce4ddf8c191e1187c5899 Mon Sep 17 00:00:00 2001 From: Felix Isaac Lim <38658663+FelixIsaac@users.noreply.github.com> Date: Sun, 24 May 2026 01:09:01 +0800 Subject: [PATCH] fix: add missing exclude patterns and skip GPG signing on commit - Add backups, cache, chrome, daemon, session-env, temp dirs to excludes - Add mcp-needs-auth-cache.json, scheduled_tasks.lock, .last-cleanup, *.lock to excludes - Fix git commit to pass -c commit.gpgsign=false so push works on machines with global GPG signing enabled --- internal/config/config.go | 10 ++++++++++ internal/git/git.go | 3 ++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/internal/config/config.go b/internal/config/config.go index 60730a2..adb662a 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -73,13 +73,23 @@ var DefaultExcludePatterns = []string{ "node_modules", "paste-cache", "image-cache", + "backups", // auto .claude.json snapshots created by CC — redundant with claude.json.age + "cache", // CC update/summary cache + "chrome", // machine-specific Chrome native host + "daemon", // machine-specific pipe key + "session-env", // per-invocation env snapshots (14k+ files) + "temp", // temporary files // Files "history.jsonl", "stats-cache.json", + "mcp-needs-auth-cache.json", // ephemeral MCP auth state + "scheduled_tasks.lock", // runtime lock file + ".last-cleanup", // timestamp marker "*.log", "*.tmp", "*.cache", "*.local-backup-*", + "*.lock", ".git", } diff --git a/internal/git/git.go b/internal/git/git.go index d28f050..d53d5ff 100644 --- a/internal/git/git.go +++ b/internal/git/git.go @@ -69,7 +69,8 @@ func (g *Git) AddAll() error { // Commit creates a commit with the given message func (g *Git) Commit(message string) error { - _, err := g.run("commit", "-m", message) + // -c commit.gpgsign=false avoids failures on machines with GPG signing enabled globally + _, err := g.run("-c", "commit.gpgsign=false", "commit", "-m", message) return err }