From 5c9fadef99990394cd68930c6d6e18cd1dfd149b Mon Sep 17 00:00:00 2001 From: Uriel Date: Sun, 15 Feb 2009 14:50:50 +0000 Subject: [PATCH] Remove xml comments from atom feed output and convert them to rc comments instead. Remove limit on atom post sized. --- apps/blagh/atom.tpl | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/apps/blagh/atom.tpl b/apps/blagh/atom.tpl index 2970b81..b691f70 100644 --- a/apps/blagh/atom.tpl +++ b/apps/blagh/atom.tpl @@ -2,8 +2,8 @@ Content-Type: application/atom+xml - %{ +# See for more info:http://www.tbray.org/ongoing/When/200x/2005/07/27/Atomic-RSS fn statpost { f = $1 @@ -15,7 +15,8 @@ fn statpost { stat=`{stat -c '%Y %U' $f} #mdate=`{/bin/date -Rd `{mtime $f|awk '{print $1}' }} # Not used because it is unreliable by=$stat(2) - ifs=() { summary=`{cat $f/index.md | crop_text 512 ... | $formatter } } + #ifs=() { summary=`{cat $f/index.md | crop_text 1024 ... | $formatter } } + ifs=() { summary=`{cat $f/index.md | $formatter } } } updated = `{/bin/date --rfc-3339'=seconds' |sed 's/ /T/'} %} @@ -30,23 +31,20 @@ updated = `{/bin/date --rfc-3339'=seconds' |sed 's/ /T/'} %($siteTitle%) %($siteSubTitle%) - +% # 2008-09-24T12:47:00-04:00 %($updated%) -%{ - for(f in `{get_post_list $blagh_root$blagh_dirs}) { - statpost $f -%} +% for(f in `{get_post_list $blagh_root$blagh_dirs}) { +% statpost $f + - +% # Maybe we should be smarter, see: http://diveintomark.org/archives/2004/05/28/howto-atom-id, example: tag:intertwingly.net,2004:2899 %($post_uri%) %($title%) - - - %($by%) - +% # + %($by%)
@@ -56,8 +54,7 @@ updated = `{/bin/date --rfc-3339'=seconds' |sed 's/ /T/'} %($updated%) - -% } +% }