From: Joey Hess Date: Fri, 13 Mar 2009 20:27:24 +0000 (-0400) Subject: unknown option wording tweak X-Git-Url: https://sipb.mit.edu/gitweb.cgi/ikiwiki.git/commitdiff_plain/f10f9e6f73f07f991c21c321b6b8c870fc501fe2?hp=12432198a68c9fb391c3ec6d284fb152f0fc3d17 unknown option wording tweak Because getopt::long is used in passthrough mode, if a known option like --wikiname that needs a parameter is specified w/o the parameter, it will not be processed, and passed on through. So in this case the "unknown option" message is innaccurate. Make it slightly better by noting that the problem can be a missing parameter. --- diff --git a/IkiWiki.pm b/IkiWiki.pm index f580d1f0d..a876bbb44 100644 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@ -533,7 +533,7 @@ sub loadplugins () { run_hooks(getopt => sub { shift->() }); if (grep /^-/, @ARGV) { - print STDERR "Unknown option: $_\n" + print STDERR "Unknown option (or missing parameter): $_\n" foreach grep /^-/, @ARGV; usage(); }