Skip to content
Snippets Groups Projects
Commit ff94b302 authored by Peterson, Peter's avatar Peterson, Peter
Browse files

Make categories universal

parent 13674e6b
No related branches found
No related tags found
No related merge requests found
......@@ -348,18 +348,12 @@ def create_category_pages(app):
# Now any additional index pages if required
if category.name in INDEX_CATEGORIES:
# index in categories directory
if category.name == 'Concepts':
category_html_dir = 'concepts/categories'
else:
category_html_dir = os.path.dirname(category.html_path)
category_html_dir = os.path.join(category.name.lower(), 'categories')
category_html_path_noext = os.path.join(category_html_dir, 'index')
yield (category_html_path_noext, context, template)
# index in document directory
if category.name == 'Concepts':
document_dir = 'concepts'
else:
document_dir = os.path.dirname(category_html_dir)
document_dir = os.path.dirname(category_html_dir)
category_html_path_noext = os.path.join(document_dir, 'index')
context['outpath'] = category_html_path_noext + '.html'
yield (category_html_path_noext, context, template)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment