Fix server static file detection for deleted files/directories in the static syncer

Related to #15174
This commit is contained in:
Bjørn Erik Pedersen
2026-08-08 16:25:53 +02:00
parent a808f6e40d
commit 2ffaf1fc1e
2 changed files with 27 additions and 1 deletions
@@ -0,0 +1,26 @@
# A deleted static file should be removed from the publish dir.
hugo server &
waitServer
exists public/static.txt
rm static/static.txt
sleep 2
! exists public/static.txt
stopServer
! stderr .
-- hugo.toml --
title = "Hugo Server Test"
baseURL = "https://example.org/"
disableKinds = ["taxonomy", "term", "sitemap"]
-- layouts/all.html --
All.
-- content/p1.md --
-- static/static.txt --
static