Fix Path actions debug screen to display number of arguments
[catagits/Catalyst-Runtime.git] / lib / Catalyst / ScriptRole.pm
index 089f2df..7ae3d7d 100644 (file)
@@ -6,7 +6,7 @@ use MooseX::Getopt;
 use namespace::autoclean;
 
 with 'MooseX::Getopt' => {
-    excludes => [qw/
+    -excludes => [qw/
         _getopt_spec_warnings
         _getopt_spec_exception
         _getopt_full_usage
@@ -14,20 +14,12 @@ with 'MooseX::Getopt' => {
 };
 
 has application_name => (
-    traits => ['NoGetopt'],
-    isa => Str,
-    is => 'ro',
+    traits   => ['NoGetopt'],
+    isa      => Str,
+    is       => 'ro',
     required => 1,
 );
 
-has help => (
-    traits => ['Getopt'],
-    isa => Bool,
-    is => 'ro',
-    documentation => q{Display this help and exit},
-    cmd_aliases => ['?', 'h'],
-);
-
 sub _getopt_spec_exception {}
 
 sub _getopt_spec_warnings {
@@ -41,11 +33,6 @@ sub _getopt_full_usage {
     exit 0;
 }
 
-before run => sub {
-    my $self = shift;
-    $self->_getopt_full_usage if $self->help;
-};
-
 sub run {
     my $self = shift;
     $self->_run_application;
@@ -74,9 +61,9 @@ Catalyst::ScriptRole - Common functionality for Catalyst scripts.
     use Moose;
     use namespace::autoclean;
 
-    with 'Catalyst::Script::Role';
+    with 'Catalyst::ScriptRole';
 
-     sub _application_args { ... }
+    sub _application_args { ... }
 
 =head1 DESCRIPTION
 
@@ -110,4 +97,3 @@ This library is free software, you can redistribute it and/or modify
 it under the same terms as Perl itself.
 
 =cut
-