From ec7cb8adc20e93bff91d8f879d50a53c6265e68b Mon Sep 17 00:00:00 2001 From: Idan Kamara Date: Sat, 24 Dec 2011 17:28:51 +0200 Subject: [PATCH] Use subscript syntax in tag archive generation Using dot caused jinja to fail if the tag contained characters such as '-' or spaces. --- hyde/ext/plugins/tagger.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hyde/ext/plugins/tagger.py b/hyde/ext/plugins/tagger.py index f239f7e..6608a88 100644 --- a/hyde/ext/plugins/tagger.py +++ b/hyde/ext/plugins/tagger.py @@ -198,7 +198,7 @@ extends: false {%% set tag = site.tagger.tags['%(tag)s'] %%} {%% set source = site.content.node_from_relative_path('%(node)s') %%} -{%% set walker = source.walk_resources_tagged_with_%(tag)s %%} +{%% set walker = source['walk_resources_tagged_with_%(tag)s'] %%} {%% extends "%(template)s" %%} """ for tagname, tag in self.site.tagger.tags.to_dict().iteritems(): @@ -212,4 +212,4 @@ extends: false archive_file = File(target.child("%s.%s" % (tagname, extension))) archive_file.delete() archive_file.write(text.strip()) - self.site.content.add_resource(archive_file) \ No newline at end of file + self.site.content.add_resource(archive_file)