we need to fetch the template anyway

This commit is contained in:
Guy Godfroy 2020-12-04 17:19:34 +01:00
parent e2edf189fc
commit 2bd0d3db47
2 changed files with 5 additions and 2 deletions

View File

@ -106,7 +106,7 @@ index_props = [
"property": "author", "property": "author",
"list": False, "list": False,
"item_dir": "authors", "item_dir": "authors",
"item_tpl"; "author", "item_tpl": "author",
"index_name": "authors", "index_name": "authors",
"index_tpl": "authors_index" "index_tpl": "authors_index"
} }

View File

@ -68,6 +68,9 @@ for dirname, subdirlist, mdlist in os.walk('.'):
# Parse the YAML header # Parse the YAML header
meta = frontmatter.parse(mdtext)[0] meta = frontmatter.parse(mdtext)[0]
# Extract template
post["template"] = meta.get("template", config.default_post_template)
# Extract post properties # Extract post properties
for prop in config.post_props: for prop in config.post_props:
post[prop] = meta.get(prop, None) post[prop] = meta.get(prop, None)