]> git.maquefel.me Git - brevno-suite/hugo/commit
commands: Preserve non-content files in convert output
authorAlexandre Vaz <xndvaz@gmail.com>
Mon, 23 Mar 2026 16:49:13 +0000 (13:49 -0300)
committerGitHub <noreply@github.com>
Mon, 23 Mar 2026 16:49:13 +0000 (17:49 +0100)
commitc4fb61d9dfb7a2a638ef69ef8ba4e4dc3ecd93ef
treef2ecf7b943a49355240e4bec4e619aaf32d19676
parentd88a29e002ebc31bf9b4e1e024f141cc0b39a657
commands: Preserve non-content files in convert output

When running `hugo convert` with `--output`, copy the content tree first so non-content bundle resources are kept in the destination, then overwrite converted content files.

Also avoid recursive self-copy when the output path points inside the content tree by skipping output directories during copy.

Fixes #4621
commands/convert.go
testscripts/commands/convert.txt