File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ class Website is export {
15
15
self . write-index;
16
16
self . collect-example-metadata;
17
17
my % examples = % ! examples-metadata ;
18
- self . write-category-indices( % examples ) ;
18
+ self . write-category-indices;
19
19
self . create-category-dirs;
20
20
self . write-example-files(% examples );
21
21
}
@@ -37,11 +37,11 @@ class Website is export {
37
37
self . p2h(EVAL slurp (' lib/HomePage.pod' ) ~ " \n \$=pod" );
38
38
}
39
39
40
- method write-category-indices ( % examples ) {
40
+ method write-category-indices {
41
41
say " Creating category index files" ;
42
42
my @ headers = qw { File Title Author } ;
43
43
for $ ! categories . categories-table. kv -> $ category , $ title {
44
- my @ examples = % examples {$ category }{" " }. values ;
44
+ my @ examples = % ! examples-metadata {$ category }{" " }. values ;
45
45
my @ rows = @ examples . map : {[. pod-link, . title, . author]};
46
46
spurt $ ! base-html-dir ~ " /$ category .html" , self . p2h(
47
47
pod-with-title($ title ,
Original file line number Diff line number Diff line change @@ -116,7 +116,8 @@ subtest {
116
116
my $ base-dir = " /tmp/website-test" ;
117
117
$ website . base-html-dir = $ base-dir ;
118
118
mkdir $ base-dir unless $ base-dir . IO . d ;
119
- $ website . write-category-indices(% examples );
119
+ $ website . examples-metadata = % examples ;
120
+ $ website . write-category-indices;
120
121
121
122
ok (($ base-dir ~ " /sender.html" ). IO . e ,
122
123
" index file for 'sender' category created" );
You can’t perform that action at this time.
0 commit comments