From 971b1aa151876cdc4b86c3634448933f42be8654 Mon Sep 17 00:00:00 2001 From: Brit Butler Date: Wed, 12 Sep 2012 14:44:44 -0400 Subject: [PATCH] Minor style tweak and flesh out tag-based feed support. --- src/feeds.lisp | 4 +++- src/indices.lisp | 13 ++++++------- src/posts.lisp | 9 ++++----- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/src/feeds.lisp b/src/feeds.lisp index d2306e2..fd0feb5 100644 --- a/src/feeds.lisp +++ b/src/feeds.lisp @@ -22,4 +22,6 @@ (render-page (make-instance 'index :path "rss.xml" :posts posts) :rss) (render-page (make-instance 'index :path "feed.atom" :posts posts) :atom) (dolist (feed feeds) - (render-page feed :rss)))) + (let ((index (index-by-tag feed by-tag))) + (setf (index-path index) (format nil "tag/~a-rss.xml" feed)) + (render-page index :rss))))) diff --git a/src/indices.lisp b/src/indices.lisp index 45ee1fd..a2d4030 100644 --- a/src/indices.lisp +++ b/src/indices.lisp @@ -6,13 +6,12 @@ (title :initform nil :initarg :title :accessor index-title))) (defmethod render ((content index) &key prev next) - (funcall (theme-fn 'index) - (list :tags (all-tags) - :months (all-months) - :config *config* - :index content - :prev prev - :next next))) + (funcall (theme-fn 'index) (list :tags (all-tags) + :months (all-months) + :config *config* + :index content + :prev prev + :next next))) (defun all-months () "Retrieve a list of all months with published posts." diff --git a/src/posts.lisp b/src/posts.lisp index fa945b7..b6fd0e2 100644 --- a/src/posts.lisp +++ b/src/posts.lisp @@ -12,11 +12,10 @@ (content :initform nil :initarg :content :accessor post-content))) (defmethod render ((content post) &key prev next) - (funcall (theme-fn 'post) - (list :config *config* - :post content - :prev prev - :next next))) + (funcall (theme-fn 'post) (list :config *config* + :post content + :prev prev + :next next))) (defun load-posts () "Read the stored .post files from the repo."