use namespace::autoclean;
with 'MooseX::Getopt' => {
- excludes => [qw/
+ -excludes => [qw/
_getopt_spec_warnings
_getopt_spec_exception
_getopt_full_usage
required => 1,
);
-has help => (
- traits => ['Getopt'],
- isa => Bool,
- is => 'ro',
- documentation => 'Display this help and exit',
- cmd_aliases => ['?', 'h'],
-);
-
has loader_class => (
isa => LoadableClass,
is => 'ro',
exit 0;
}
-before run => sub {
- my $self = shift;
- $self->_getopt_full_usage if $self->help;
-};
-
sub run {
my $self = shift;
$self->_run_application;