shithub: hugo

Download patch

ref: 882d678bbf2a149a90e2aed4341d7f6fc2cb394d
parent: fa28df1058e0131364cea2e3ac7f80e934d024a1
author: Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
date: Wed Jul 24 17:46:24 EDT 2019

modules: Rename disabled => disable in config

--- a/hugolib/hugo_modules_test.go
+++ b/hugolib/hugo_modules_test.go
@@ -307,7 +307,7 @@
 path="a"
 [[module.imports]]
 path="b"
-disabled=true
+disable=true
 
 
 `)
--- a/modules/collect.go
+++ b/modules/collect.go
@@ -284,7 +284,7 @@
 	}
 
 	for _, moduleImport := range moduleConfig.Imports {
-		disabled := disabled || moduleImport.Disabled
+		disabled := disabled || moduleImport.Disable
 
 		if !c.isSeen(moduleImport.Path) {
 			tc, err := c.add(owner, moduleImport, disabled)
--- a/modules/config.go
+++ b/modules/config.go
@@ -301,7 +301,7 @@
 type Import struct {
 	Path         string // Module path
 	IgnoreConfig bool   // Ignore any config.toml found.
-	Disabled     bool   // Turn off this module.
+	Disable     bool   // Turn off this module.
 	Mounts       []Mount
 }