diff options
Diffstat (limited to 'modules/config.go')
-rw-r--r-- | modules/config.go | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/modules/config.go b/modules/config.go index f8faf7969..62671613c 100644 --- a/modules/config.go +++ b/modules/config.go @@ -29,7 +29,6 @@ import ( const WorkspaceDisabled = "off" var DefaultModuleConfig = Config{ - // Default to direct, which means "git clone" and similar. We // will investigate proxy settings in more depth later. // See https://github.com/golang/go/issues/26334 @@ -58,7 +57,6 @@ var DefaultModuleConfig = Config{ // ApplyProjectConfigDefaults applies default/missing module configuration for // the main project. func ApplyProjectConfigDefaults(mod Module, cfgs ...config.AllProvider) error { - moda := mod.(*moduleAdapter) // To bridge between old and new configuration format we need @@ -99,14 +97,19 @@ func ApplyProjectConfigDefaults(mod Module, cfgs ...config.AllProvider) error { dir = dirs.ContentDir dropLang = dir == dirsBase.ContentDir case files.ComponentFolderData: + //lint:ignore SA1019 Keep as adapter for now. dir = dirs.DataDir case files.ComponentFolderLayouts: + //lint:ignore SA1019 Keep as adapter for now. dir = dirs.LayoutDir case files.ComponentFolderI18n: + //lint:ignore SA1019 Keep as adapter for now. dir = dirs.I18nDir case files.ComponentFolderArchetypes: + //lint:ignore SA1019 Keep as adapter for now. dir = dirs.ArcheTypeDir case files.ComponentFolderAssets: + //lint:ignore SA1019 Keep as adapter for now. dir = dirs.AssetDir case files.ComponentFolderStatic: // For static dirs, we only care about the language in multihost setups. @@ -230,6 +233,7 @@ func decodeConfig(cfg config.Provider, pathReplacements map[string]string) (Conf c.Workspace = filepath.Join(workingDir, c.Workspace) } if _, err := os.Stat(c.Workspace); err != nil { + //lint:ignore ST1005 end user message. return c, fmt.Errorf("module workspace %q does not exist. Check your module.workspace setting (or HUGO_MODULE_WORKSPACE env var).", c.Workspace) } } |