From 2b933faaf2f9aba9158d56c49367e423ea1a2ea3 Mon Sep 17 00:00:00 2001 From: Samrat Man Singh Date: Wed, 11 Jul 2012 08:52:00 +0545 Subject: [PATCH] Add usage and intallation instructions --- pelican/plugins/related_posts.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/pelican/plugins/related_posts.py b/pelican/plugins/related_posts.py index b697d488..808d6f47 100644 --- a/pelican/plugins/related_posts.py +++ b/pelican/plugins/related_posts.py @@ -5,7 +5,29 @@ Related posts plugin for Pelican ================================ Adds related_posts variable to article's context + +Settings +-------- +To enable, add + + from pelican.plugins import related_posts + PLUGINS = [related_posts] + +to your settings.py. + +Usage +----- + {% if article.related_posts %} + + {% endif %} + + """ + related_posts = [] def add_related_posts(generator, metadata): if 'tags' in metadata: