This seems buggy, but I’m just learning how hugo fits together and I might well have got something upside down, or left out a part somewhere.
I’ve got this inside a file content/posts/nbd/towards-a-better-nbd.md
:
window.location = "{{< ref "/pages/thanks-for-signing-up.md" >}}";
This file renders fine under hugo serve
, and the generated link works. I have a file content/pages/thanks-for-signing-up.md
present, and it renders when I visit http://localhost:1313/pages/thanks-for-signing-up/
.
However, when I run hugo --destination=../public
, it fails with this error:
Building sites … ERROR 2018/05/05 12:07:08 error processing shortcode "_internal/shortcodes/ref.html" for page "posts/nbd/towards-a-better-nbd.md": template: _internal/shortcodes/ref.html:1:73: executing "_internal/shortcodes/ref.html" at <ref .Page (.Get 0)>: error calling ref: No page found with path or logical name "pages/thanks-for-signing-up.md".
There doesn’t seem to be any combination of pathname parts I can pass to ref
to get it to see the file when I do a static build, despite it working fine under hugo serve
.
I’m using the Kiss
template, and hugo version
says this:
$ hugo version
Hugo Static Site Generator v0.41-DEV-8B03C51 linux/amd64 BuildDate: 2018-04-30T21:16:27+0100
Have I done something wrong, or is this a bug?