commands: Make the server flag --renderToDisk into --renderToMemory (note)

Fixes #11987
This commit is contained in:
Bjørn Erik Pedersen
2024-02-05 09:44:28 +01:00
parent 58d7f83390
commit 9c6d377872
13 changed files with 28 additions and 28 deletions

View File

@@ -928,7 +928,7 @@ func (c *hugoBuilder) hugoTry() *hugolib.HugoSites {
func (c *hugoBuilder) loadConfig(cd *simplecobra.Commandeer, running bool) error {
cfg := config.New()
cfg.Set("renderToDisk", (c.s == nil && !c.r.renderToMemory) || (c.s != nil && c.s.renderToDisk))
cfg.Set("renderToMemory", c.r.renderToMemory)
watch := c.r.buildWatch || (c.s != nil && c.s.serverWatch)
if c.r.environment == "" {
// We need to set the environment as early as possible because we need it to load the correct config.