safe => 0,
rebuild => 0,
},
+ setup => {
+ type => "internal",
+ default => undef,
+ description => "running in setup mode",
+ safe => 0,
+ rebuild => 0,
+ },
refresh => {
type => "internal",
default => 0,
safe => 0,
rebuild => 0,
},
- setup => {
+ setupfile => {
type => "internal",
default => undef,
- description => "setup file to read",
+ description => "path to setup file",
safe => 0,
rebuild => 0,
},
sub load ($) { # {{{
my $setup=IkiWiki::possibly_foolish_untaint(shift);
- $config{setupfile}=File::Spec->rel2abs($config{setup});
- delete $config{setup};
+ $config{setupfile}=File::Spec->rel2abs($setup);
+
#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, $!));
account. Also, avoid making index pages for directories that contain
no files.
* external: Fix support for hooks called in an array context.
+ * Options set in the setup file are now immediatly loaded by ikiwiki -setup.
+ This allows later switches to override them. Previously, setup file
+ options overrode most command line options.
-- Joey Hess <joeyh@debian.org> Mon, 21 Jul 2008 11:35:46 -0400
eval q{use Getopt::Long};
Getopt::Long::Configure('pass_through');
GetOptions(
- "setup|s=s" => \$config{setup},
+ "setup|s=s" => sub {
+ require IkiWiki::Setup;
+ IkiWiki::Setup::load($_[1]);
+ $config{setup}=1;
+ },
"dumpsetup|s=s" => \$config{dumpsetup},
"wikiname=s" => \$config{wikiname},
"verbose|v!" => \$config{verbose},
getconfig();
if ($config{setup}) {
- require IkiWiki::Setup;
- IkiWiki::Setup::load($config{setup});
-
+ delete $config{setup};
loadplugins();
checkconfig();
if (! $config{refresh}) {
$config{rebuild}=1;
}
-
- # ignore syslog setting from setup file
- # while doing initial setup
- $config{syslog}=0 unless $config{dumpsetup};
}
if ($config{dumpsetup}) {
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2008-08-05 20:43-0400\n"
+"POT-Creation-Date: 2008-08-06 01:51-0400\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
msgid "You are banned."
msgstr ""
-#: ../IkiWiki/CGI.pm:783 ../IkiWiki/CGI.pm:784 ../IkiWiki.pm:1110
+#: ../IkiWiki/CGI.pm:783 ../IkiWiki/CGI.pm:784 ../IkiWiki.pm:1117
msgid "Error"
msgstr ""
msgid "deleting bucket.."
msgstr ""
-#: ../IkiWiki/Plugin/amazon_s3.pm:38 ../ikiwiki.in:194
+#: ../IkiWiki/Plugin/amazon_s3.pm:38 ../ikiwiki.in:192
msgid "done"
msgstr ""
msgid "attachment upload"
msgstr ""
-#: ../IkiWiki/Plugin/autoindex.pm:74
+#: ../IkiWiki/Plugin/autoindex.pm:77
msgid "automatic index generation"
msgstr ""
msgid "usage: ikiwiki [options] source dest"
msgstr ""
-#: ../ikiwiki.in:79
+#: ../ikiwiki.in:83
msgid "usage: --set var=value"
msgstr ""
-#: ../ikiwiki.in:127
+#: ../ikiwiki.in:129
msgid "generating wrappers.."
msgstr ""
-#: ../ikiwiki.in:183
+#: ../ikiwiki.in:181
msgid "rebuilding wiki.."
msgstr ""
-#: ../ikiwiki.in:186
+#: ../ikiwiki.in:184
msgid "refreshing wiki.."
msgstr ""
-#: ../IkiWiki.pm:427
+#: ../IkiWiki.pm:434
msgid "Must specify url to wiki with --url when using --cgi"
msgstr ""
-#: ../IkiWiki.pm:471
+#: ../IkiWiki.pm:478
msgid "cannot use multiple rcs plugins"
msgstr ""
-#: ../IkiWiki.pm:1093
+#: ../IkiWiki.pm:1100
#, perl-format
msgid "preprocessing loop detected on %s at depth %i"
msgstr ""
-#: ../IkiWiki.pm:1581
+#: ../IkiWiki.pm:1588
msgid "yes"
msgstr ""