Make aggregated items be internal pages if --aggregateinternal is used.
This addresses <http://ikiwiki.info/todo/aggregate_to_internal_pages/> in a simple way. With this approach, a flag day is required, on which all users of aggregated pages start to inline them using the internal() pagespec; after that, the aggregateinternal option can safely be switched on in the setup file (and the old aggregated pages can be deleted by hand).master
parent
ee4e6058e3
commit
5c0896e674
|
@ -30,7 +30,10 @@ sub getopt () { #{{{
|
|||
eval q{use Getopt::Long};
|
||||
error($@) if $@;
|
||||
Getopt::Long::Configure('pass_through');
|
||||
GetOptions("aggregate" => \$config{aggregate});
|
||||
GetOptions(
|
||||
"aggregate" => \$config{aggregate},
|
||||
"aggregateinternal!" => \$config{aggregateinternal},
|
||||
);
|
||||
} #}}}
|
||||
|
||||
sub checkconfig () { #{{{
|
||||
|
@ -595,7 +598,7 @@ sub pagefile ($) { #{{{
|
|||
} #}}}
|
||||
|
||||
sub htmlfn ($) { #{{{
|
||||
return shift().".".$config{htmlext};
|
||||
return shift().".".($config{aggregateinternal} ? "_" : "").$config{htmlext};
|
||||
} #}}}
|
||||
|
||||
my $aggregatelock;
|
||||
|
|
Loading…
Reference in New Issue