summaryrefslogtreecommitdiff
path: root/haunt.scm
diff options
context:
space:
mode:
Diffstat (limited to 'haunt.scm')
-rw-r--r--haunt.scm9
1 files changed, 8 insertions, 1 deletions
diff --git a/haunt.scm b/haunt.scm
index 8a58caa..913c16a 100644
--- a/haunt.scm
+++ b/haunt.scm
@@ -13,8 +13,15 @@
(define post-prefix "post")
+(define (posts/reverse-file-name posts)
+ "Returns POSTS sorted in reverse file name order."
+ (sort posts
+ (lambda (a b)
+ (string>? (post-file-name a) (post-file-name b)))))
+
(define (filter-now posts)
- (filter (lambda (p) (member "now" (post-tags p))) posts))
+ (posts/reverse-file-name
+ (filter (lambda (p) (member "now" (post-tags p))) posts)))
(define (filter-not-now posts)
(posts/reverse-chronological