Good morning, intrepid present-day viewers. The issue has been resolved in 0.20. Thank you much, Hugo.
Hey what's good. I was having issues creating new posts based on archetypes provided by the theme. Enclosed was a self-contained repository demonstrating the issue.
The files in content/test/
were the output of hugo new
with various hugo versions and options. The suffix denotes the hugo version used. If the filename contains "with-switch"
, it was generated with hugo new -k test test/<...>
.
This repository was created in the following manner:
hugo new site hugo-theme-archetype-issue
.hugo new theme test-theme
.- Add
theme = "test-theme"
toconfig.toml
. - Create
themes/test-theme/archetypes/test.md
.
Two different hugo
binaries were used. To install the one responsible for the 0.19
files, run brew install hugo
. To install the one responsible for the master
files, run go get -u -v github.com/spf13/hugo
. (This is no longer the case on master)
To reproduce the issue, run the following:
hugo new test/test-0.19.md
hugo new -k test test/test-with-switch-0.19.md
$GOPATH/bin/hugo new test/test-master.md
$GOPATH/bin/hugo new -k test test/test-with-switch-master.md
In all cases, I would expect the output files to contain title
, date
, and blurb
in the front matter.