From aae200eeeafb5e4ccd875512ffad96779230bf03 Mon Sep 17 00:00:00 2001 From: Zeusina Date: Sun, 15 Mar 2026 21:35:59 +0300 Subject: [PATCH] fix: :bug: fixed failed error message on non changes --- git.go | 5 +++-- reconcile.go | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/git.go b/git.go index ad4f63a..fbe88ac 100644 --- a/git.go +++ b/git.go @@ -87,9 +87,10 @@ func GitPull(cfg *Config) error { return nil } -// GitStatusChanged reports true when the working tree has uncommitted changes. +// GitStatusChanged reports true when there are changes in the machine-managed +// dynamic directory. Unrelated repository changes are intentionally ignored. func GitStatusChanged(cfg *Config) (bool, error) { - out, err := gitOutput(cfg, "status", "--porcelain") + out, err := gitOutput(cfg, "status", "--porcelain", "--", cfg.DynamicDir) if err != nil { return false, err } diff --git a/reconcile.go b/reconcile.go index f3b470b..68f7469 100644 --- a/reconcile.go +++ b/reconcile.go @@ -82,7 +82,7 @@ func Reconcile(cfg *Config) { return } if !changed { - slog.Info("reconcile complete — no changes to commit") + slog.Info("reconcile complete — no dynamic DNS changes to commit") return }