From c182f5fa5a0cd6383e1149cc6ddeac9af70a614c Mon Sep 17 00:00:00 2001 From: Ahmet Bakan Date: Tue, 23 Sep 2014 21:26:59 -0700 Subject: [PATCH] Fixed some templeate issues to be released as v0.3.1. --- ablog/__init__.py | 2 +- ablog/post.py | 6 ++++-- ablog/templates/archive.html | 3 +-- docs/release/ablog-v0.3-released.rst | 21 ++++++++++++++++++++- 4 files changed, 26 insertions(+), 6 deletions(-) diff --git a/ablog/__init__.py b/ablog/__init__.py index f278cf8..7e2f474 100755 --- a/ablog/__init__.py +++ b/ablog/__init__.py @@ -8,7 +8,7 @@ from .post import (PostDirective, PostListDirective, UpdateDirective, UpdateNode, process_posts, process_postlist, purge_posts, generate_archive_pages) -__version__ = '0.3' +__version__ = '0.3.1' def anchor(post): diff --git a/ablog/post.py b/ablog/post.py index 798497a..e458385 100644 --- a/ablog/post.py +++ b/ablog/post.py @@ -401,7 +401,8 @@ def generate_archive_pages(app): 'catalog': catalog, 'summary': True, 'atom_feed': atom_feed, - 'feed_path': blog.blog_path + 'feed_path': blog.blog_path, + 'archive_feed': False, } yield (catalog.docname, context, 'archive.html') @@ -417,7 +418,8 @@ def generate_archive_pages(app): 'catalog': [collection], 'summary': True, 'atom_feed': atom_feed, - 'feed_path': collection.path + 'feed_path': collection.path if blog.blog_feed_archives else blog.blog_path, + 'archive_feed': atom_feed and blog.blog_feed_archives } yield (collection.docname, context, 'archive.html') diff --git a/ablog/templates/archive.html b/ablog/templates/archive.html index 448fa3f..83222cb 100644 --- a/ablog/templates/archive.html +++ b/ablog/templates/archive.html @@ -20,7 +20,7 @@

- {% if atom_feed and fa %} + {% if archive_feed and fa %} {% endif %} {{ header }} {% if archive.href %} @@ -44,7 +44,6 @@ {% endif %} {% include "postcard2.html" %} - {{ post.to_html(archive.docname) }}

{{ _("Read more ...") }}


diff --git a/docs/release/ablog-v0.3-released.rst b/docs/release/ablog-v0.3-released.rst index 50412e3..5514af5 100644 --- a/docs/release/ablog-v0.3-released.rst +++ b/docs/release/ablog-v0.3-released.rst @@ -18,4 +18,23 @@ improvements: * You can list language archives on your website by adding ``languages.html`` to :confval:`html_sidebars` configuration option. - * :rst:dir:`postlist` directive takes options to filter posts. \ No newline at end of file + * :rst:dir:`postlist` directive takes options to filter posts. + + +ABlog v0.3.1 released +--------------------- + +.. post:: Sep 24, 2014 + :author: Ahmet + :category: Release + :location: SF + +ABlog v0.3.1 is a minor release to fix two issues in templates: + + * Links to collection (archive) feeds is displayed only on collection page + (e.g. :ref:`category-manual`), not on a catalog page that lists posts + for multiple collections (e.g. :ref:`blog-categories`). + + * Links to collection feeds is displayed only when they are generated + (see :confval:`blog_feed_archives`). Previously, links would be generated + to feeds that did not exist.