X-Git-Url: https://sipb.mit.edu/gitweb.cgi/ikiwiki.git/blobdiff_plain/ed75653e4d1ebc9827601ab3649e1422f45ef338..d092e794b346e59318fe05bbe456e8fc3085a97f:/IkiWiki.pm diff --git a/IkiWiki.pm b/IkiWiki.pm index 88407584f..0440f4020 100644 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@ -103,6 +103,12 @@ sub checkconfig () { #{{{ } } + if (ref $config{ENV} eq 'HASH') { + foreach my $val (keys %{$config{ENV}}) { + $ENV{$val}=$config{ENV}{$val}; + } + } + if ($config{w3mmode}) { eval q{use Cwd q{abs_path}}; error($@) if $@; @@ -1256,6 +1262,7 @@ sub pagespec_translate ($) { #{{{ $code=0; } + no warnings; return eval 'sub { my $page=shift; '.$code.' }'; } #}}} @@ -1270,7 +1277,7 @@ sub pagespec_match ($$;@) { #{{{ } my $sub=pagespec_translate($spec); - return IkiWiki::FailReason->new('syntax error') if $@; + return IkiWiki::FailReason->new("syntax error in pagespec \"$spec\"") if $@; return $sub->($page, @params); } #}}}