[Catalyst-commits] r12017 - in Catalyst-Runtime/5.80/branches/better_scripts: . lib/Catalyst

t0m at dev.catalyst.perl.org t0m at dev.catalyst.perl.org
Thu Nov 26 00:25:01 GMT 2009


Author: t0m
Date: 2009-11-26 00:25:01 +0000 (Thu, 26 Nov 2009)
New Revision: 12017

Modified:
   Catalyst-Runtime/5.80/branches/better_scripts/Makefile.PL
   Catalyst-Runtime/5.80/branches/better_scripts/TODO.scripts
   Catalyst-Runtime/5.80/branches/better_scripts/lib/Catalyst/ScriptRole.pm
Log:
Get useful help about which option you fucked up back

Modified: Catalyst-Runtime/5.80/branches/better_scripts/Makefile.PL
===================================================================
--- Catalyst-Runtime/5.80/branches/better_scripts/Makefile.PL	2009-11-25 22:51:28 UTC (rev 12016)
+++ Catalyst-Runtime/5.80/branches/better_scripts/Makefile.PL	2009-11-26 00:25:01 UTC (rev 12017)
@@ -48,7 +48,7 @@
 requires 'Task::Weaken';
 requires 'Text::Balanced'; # core in 5.8.x but mentioned for completeness
 requires 'MRO::Compat';
-requires 'MooseX::Getopt';
+requires 'MooseX::Getopt' => '0.25';
 requires 'MooseX::Types';
 requires 'String::RewritePrefix' => '0.004'; # Catalyst::Utils::resolve_namespace
 

Modified: Catalyst-Runtime/5.80/branches/better_scripts/TODO.scripts
===================================================================
--- Catalyst-Runtime/5.80/branches/better_scripts/TODO.scripts	2009-11-25 22:51:28 UTC (rev 12016)
+++ Catalyst-Runtime/5.80/branches/better_scripts/TODO.scripts	2009-11-26 00:25:01 UTC (rev 12017)
@@ -1,2 +1,2 @@
-* Sort out help so that it shows what you fucked up.
-* Fix horrible hacking around MX::Getopt's help display - probably by fixing MX::Getopt.
+* Fix the horrible hacking that is Catalyst::ScriptRole::Useage
+* Fix TODO tests

Modified: Catalyst-Runtime/5.80/branches/better_scripts/lib/Catalyst/ScriptRole.pm
===================================================================
--- Catalyst-Runtime/5.80/branches/better_scripts/lib/Catalyst/ScriptRole.pm	2009-11-25 22:51:28 UTC (rev 12016)
+++ Catalyst-Runtime/5.80/branches/better_scripts/lib/Catalyst/ScriptRole.pm	2009-11-26 00:25:01 UTC (rev 12017)
@@ -5,7 +5,12 @@
 use MooseX::Getopt;
 use namespace::autoclean;
 
-with 'MooseX::Getopt';
+with 'MooseX::Getopt' => {
+    excludes => [qw/
+        _getopt_spec_warnings
+        _getopt_spec_exception
+    /],
+};
 
 has application_name => (
     traits => ['NoGetopt'],
@@ -21,6 +26,13 @@
     documentation => q{Display this help and exit},
 );
 
+sub _getopt_spec_exception {}
+
+sub _getopt_spec_warnings {
+    shift;
+    warn @_;
+}
+
 sub _exit_with_usage {
     my $self = shift;
     pod2usage();




More information about the Catalyst-commits mailing list