makesite: Add the variable file_name
This commit is contained in:
parent
2b54284d2d
commit
a1eb445bff
@ -141,6 +141,8 @@ def make_pages(src, dst, layout, **params):
|
||||
if 'params' in content:
|
||||
page_params.update(**json.loads(open(content['params'], 'r').read()))
|
||||
|
||||
page_params['file_name'] = os.path.basename(src_path)
|
||||
|
||||
# Populate placeholders in content if content-rendering is enabled.
|
||||
if page_params.get('render') == 'yes':
|
||||
rendered_content = render(page_params['content'], **page_params)
|
||||
|
Loading…
Reference in New Issue
Block a user