X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/e910e67424aeaf56c547578af6c98914a7180811..376944cb026945ab597db01eb1e3aea4fa320007:/IkiWiki/Setup.pm?ds=sidebyside diff --git a/IkiWiki/Setup.pm b/IkiWiki/Setup.pm index 0c8ad9208..235e93eaf 100644 --- a/IkiWiki/Setup.pm +++ b/IkiWiki/Setup.pm @@ -2,13 +2,17 @@ use warnings; use strict; +use IkiWiki; +use open qw{:utf8 :std}; package IkiWiki; sub setup () { # {{{ my $setup=possibly_foolish_untaint($config{setup}); delete $config{setup}; - open (IN, $setup) || error("read $setup: $!\n"); + #translators: The first parameter is a filename, and the second + #translators: is a (probably not translated) error message. + open (IN, $setup) || error(sprintf(gettext("cannot read %s: %s"), $setup, $!)); my $code; { local $/=undef; @@ -18,7 +22,8 @@ sub setup () { # {{{ close IN; eval $code; - error($@) if $@; + error("$setup: ".$@) if $@; + exit; } #}}}