Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gohugoio/hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tpl
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2017-04-12 21:40:36 +0300
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2017-04-13 12:19:54 +0300
commit077005e514b1ed50d84ceb90c7c72f184cb04521 (patch)
tree4154c7825764929c4c2b3a07e4cef8e971957982 /tpl
parentefc0e05c4ef974414b010b3fba5e40dab0d43876 (diff)
output: Fix base theme vs project base template logic
Fixes #3323
Diffstat (limited to 'tpl')
-rw-r--r--tpl/tplimpl/template.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/tpl/tplimpl/template.go b/tpl/tplimpl/template.go
index c14d24146..f1ab37ee0 100644
--- a/tpl/tplimpl/template.go
+++ b/tpl/tplimpl/template.go
@@ -420,13 +420,15 @@ func (t *templateHandler) loadTemplates(absPath string, prefix string) {
li := strings.LastIndex(path, layoutDir) + len(layoutDir) + 1
relPath := path[li:]
+ templateDir := path[:li-len(layoutDir)-1]
descriptor := output.TemplateLookupDescriptor{
+ TemplateDir: templateDir,
WorkingDir: workingDir,
LayoutDir: layoutDir,
RelPath: relPath,
Prefix: prefix,
- Theme: t.PathSpec.Theme(),
+ ThemeDir: themeDir,
OutputFormats: t.OutputFormatsConfig,
FileExists: func(filename string) (bool, error) {
return helpers.Exists(filename, t.Fs.Source)