From 6782a873d9d87fcd275524b278802df283a60ae5 Mon Sep 17 00:00:00 2001 From: John Coffey Date: Tue, 24 Nov 2026 23:03:33 -0700 Subject: [PATCH] indexnow: accept a committed build without its marker A site that commits public/ keeps .hotdog-cms-pages in git but ignores .hotdog-cms-build, so a deploy from a fresh checkout has no marker and hotdog-cms indexnow refused it. It needs the page manifest, so check that. --- cmd/hotdog-cms/main.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/cmd/hotdog-cms/main.go b/cmd/hotdog-cms/main.go index c81ce3b..5e9ee92 100644 --- a/cmd/hotdog-cms/main.go +++ b/cmd/hotdog-cms/main.go @@ -315,8 +315,11 @@ func cmdIndexNow(args []string) error { if out == "" { out = filepath.Join(*dir, "public") } - if _, err := os.Stat(filepath.Join(out, build.Marker)); err != nil { - return fmt.Errorf("%s is not a hotdog-cms build; run hotdog-cms build first", out) + // The page manifest, not the build marker: a site that commits public/ + // keeps the manifest in git but usually ignores the marker (it holds the + // build time), and a deploy from a fresh checkout has only what git has. + if _, err := os.Stat(filepath.Join(out, build.PagesManifest)); err != nil { + return fmt.Errorf("%s has no %s; run hotdog-cms build first", out, build.PagesManifest) } n := *name if n == "" { -- 2.54.0