aboutsummaryrefslogtreecommitdiff
path: root/lib/WebCoso/Maker.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/WebCoso/Maker.pm')
-rw-r--r--lib/WebCoso/Maker.pm41
1 files changed, 40 insertions, 1 deletions
diff --git a/lib/WebCoso/Maker.pm b/lib/WebCoso/Maker.pm
index 4bc6dbb..c4659be 100644
--- a/lib/WebCoso/Maker.pm
+++ b/lib/WebCoso/Maker.pm
@@ -107,6 +107,22 @@ my @passes=(
'=',
\&parseRST],
+ # feeds
+ ["$WebCoso::Common::SRCPATH/(**)/feed.(*).xml",
+ ':',
+ "$WebCoso::Common::SRCPATH/_webcoso/tags.yml",
+ "$WebCoso::Common::SRCPATH/_webcoso/changes.yml",
+ "$WebCoso::Common::SRCPATH/\$1/feed.\$2.tt",
+ '=',
+ $template->expandTT()],
+ ["$WebCoso::Common::SRCPATH/feed.(*).xml",
+ ':',
+ "$WebCoso::Common::SRCPATH/_webcoso/tags.yml",
+ "$WebCoso::Common::SRCPATH/_webcoso/changes.yml",
+ "$WebCoso::Common::SRCPATH/feed.\$1.tt",
+ '=',
+ $template->expandTT()],
+
# tags from normal documents (tag documents can't be tagged!)
["$WebCoso::Common::SRCPATH/_webcoso/tags.yml",
@@ -177,6 +193,18 @@ my @passes=(
"$WebCoso::Common::SRCPATH/document.\$2.du.xml",
'=',
$xslt->du2html()],
+
+ # feeds
+ ["$WebCoso::Common::DSTPATH/(**)/feed.(*).xml",
+ ':',
+ "$WebCoso::Common::SRCPATH/\$1/feed.\$2.xml",
+ '=',
+ $xslt->fillFeed()],
+ ["$WebCoso::Common::DSTPATH/feed.(*).xml",
+ ':',
+ "$WebCoso::Common::SRCPATH/feed.\$1.xml",
+ '=',
+ $xslt->fillFeed()],
],
%maker_opts,
}),
@@ -197,7 +225,18 @@ my @passes=(
=~s{^\Q$WebCoso::Common::SRCPATH\E/tags/}{$WebCoso::Common::DSTPATH/tags/};
return $file;
},
- })]},
+ }),
+ WebCoso::Common::fromTo("$WebCoso::Common::SRCPATH/",
+ {
+ files=>sub{m{^feed\.}},
+ dirs=>sub{!m{^[_.]}},
+ transform=>sub{
+ (my $file=$_[0]
+ =~s{^\Q$WebCoso::Common::SRCPATH\E/}{$WebCoso::Common::DSTPATH/};
+ return $file;
+ },
+ }),
+ ]},
);
sub make {