mirror of
https://github.com/gohugoio/hugo.git
synced 2026-08-24 15:28:54 +00:00
1eea9fba0b
Closes #14763 Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
24 lines
517 B
Plaintext
24 lines
517 B
Plaintext
# Issue 14763
|
|
|
|
# The staging config should not apply.
|
|
hugo config
|
|
! stdout 'myparam'
|
|
mkdir content
|
|
hugo new content foo.md
|
|
hugo -DF
|
|
! grep 'foo' public/foo/index.html
|
|
|
|
# The staging config should apply.
|
|
hugo config -e staging
|
|
stdout 'myparam'
|
|
hugo new content bar.md -e staging
|
|
hugo -DF -e staging
|
|
grep 'myparam: foo|' public/bar/index.html
|
|
|
|
-- config/_default/hugo.toml --
|
|
baseURL = "https://example.com"
|
|
-- config/staging/params.toml --
|
|
myparam = "foo"
|
|
-- layouts/single.html --
|
|
myparam: {{ site.Params.myparam }}|
|