Plugin version: Rev: 13222 (26 Mar 2007)
Parameters in a config topic which are set to the empty value are incorrectly parsed; the value is taken to be the entirety of the following line. The problem seems that the
\s
regexp pattern matches newlines (I'm using Perl 5.8.8).
Here's a brief debugging session (at
Publish.pm:136
) using the provided
PublishWeb
topic as the config topic. I'm running this as
perl -dT ./publish Public configtopic=Public.PublishWeb
Using the shipped regexp to split out the variables results in this:
DB<57> while( $cfgt =~ s/^\s+\*\s+Set\s+([A-Z]+)\s*=\s*(.*?)\s*$//m ) { print "$1 = '$2'\n" }
INSTANCE = '* Comma-separated list of [[PublishContrib#WildcardPattern][wildcard patterns]] that match the names of topics to *include*'
INCLUSIONS = '*'
EXCLUSIONS = 'Web*,Publish*'
FILTER = '* Skin for published HTML'
PUBLISHSKIN = 'text'
TEMPLATES = 'view'
FORMAT = 'file'
EXTRAS = '* Name of the publish history topic to us. Default is PublishContribHistory'
HISTORY = '<form method="POST" name="rename" action="%SCRIPTURLPATH%/publish%SCRIPTSUFFIX%/%WEB%">'
Which isn't quite what's expected. Changing the offending
\s
patterns to
[:blank:]
(which according to the Perl docs matches "all horizontal whitespace") results in:
DB<60> while( $cfgt =~ s/^\s+\*\s+Set\s+([A-Z]+)\s*=[[:blank:]]*(.*?)[[:blank:]]*$//m ) { print "$1 = '$2'\n" }
INSTANCE = ''
INCLUSIONS = '*'
EXCLUSIONS = 'Web*,Publish*'
FILTER = ''
PUBLISHSKIN = 'text'
TEMPLATES = 'view'
FORMAT = 'file'
EXTRAS = ''
HISTORY = ''
--
TWiki:Main/DiabJerius
- 13 Sep 2007
Done
CC