From bfc963a0657f9d49001f5d4092f0f793b9e50899 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexis=20M=C3=A9taireau?= Date: Tue, 30 Oct 2012 18:57:06 +0100 Subject: [PATCH] We pass lists, not dicst! --- docs/themes.rst | 11 ++++++----- pelican/generators.py | 2 -- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/docs/themes.rst b/docs/themes.rst index d06c97a8..e482bc9b 100644 --- a/docs/themes.rst +++ b/docs/themes.rst @@ -60,9 +60,10 @@ articles The list of articles, ordered descending by date etc.) dates The same list of articles, but ordered by date, ascending -tags A key-value dict containing the tags (the keys) and - the list of respective articles (the values) -categories A key-value dict containing the categories (keys) +tags A list of (tag, articles) tuples, containing all + the tags. +categories A list of (category, articles) tuples, containing + all the categories. and the list of respective articles (values) pages The list of pages ============= =================================================== @@ -108,7 +109,7 @@ dates_paginator A paginator object for the article list, ordered by date, ascending. dates_page The current page of articles, ordered by date, ascending. -page_name AUTHOR_URL where everything after `{slug}` is +page_name AUTHOR_URL where everything after `{slug}` is removed -- useful for pagination links =================== =================================================== @@ -134,7 +135,7 @@ dates_paginator A paginator object for the list of articles, ordered by date, ascending dates_page The current page of articles, ordered by date, ascending -page_name CATEGORY_URL where everything after `{slug}` is +page_name CATEGORY_URL where everything after `{slug}` is removed -- useful for pagination links =================== =================================================== diff --git a/pelican/generators.py b/pelican/generators.py index f056484a..01f4701c 100644 --- a/pelican/generators.py +++ b/pelican/generators.py @@ -42,7 +42,6 @@ class Generator(object): os.path.join(self.theme, 'templates'))) self._templates_path += self.settings.get('EXTRA_TEMPLATES_PATHS', []) - theme_path = os.path.dirname(os.path.abspath(__file__)) simple_loader = FileSystemLoader(os.path.join(theme_path, @@ -283,7 +282,6 @@ class ArticlesGenerator(Generator): self.generate_articles(write) self.generate_direct_templates(write) - # and subfolders after that self.generate_tags(write) self.generate_categories(write)