File Coverage

blib/lib/Kevin/Command/kevin.pm
Criterion Covered Total %
statement 3 4 75.0
branch n/a
condition n/a
subroutine 1 2 50.0
pod 1 1 100.0
total 5 7 71.4


line stmt bran cond sub pod time code
1             package Kevin::Command::kevin;
2             $Kevin::Command::kevin::VERSION = '0.7.1';
3             # ABSTRACT: Alternative Minion command
4 1     1   839 use Mojo::Base 'Mojolicious::Commands';
  1         2  
  1         4  
5              
6             has description => 'Minion job queue alternative commands';
7             has hint => <
8              
9             See 'APPLICATION kevin help COMMAND' for more information on a specific
10             command.
11             EOF
12             has message => sub { shift->extract_usage . "\nCommands:\n" };
13             has namespaces => sub { [map "${_}::kevin", @{shift->app->commands->namespaces}] };
14              
15 0     0 1   sub help { shift->run(@_) }
16              
17             1;
18              
19             #pod =encoding utf8
20             #pod
21             #pod =head1 SYNOPSIS
22             #pod
23             #pod Usage: APPLICATION kevin COMMAND [OPTIONS]
24             #pod
25             #pod =head1 DESCRIPTION
26             #pod
27             #pod L lists available alternative L commands.
28             #pod
29             #pod =head1 ATTRIBUTES
30             #pod
31             #pod L inherits all attributes from
32             #pod L and implements the following new ones.
33             #pod
34             #pod =head2 description
35             #pod
36             #pod my $description = $command->description;
37             #pod $command = $command->description('Foo');
38             #pod
39             #pod Short description of this command, used for the command list.
40             #pod
41             #pod =head2 hint
42             #pod
43             #pod my $hint = $command->hint;
44             #pod $command = $command->hint('Foo');
45             #pod
46             #pod Short hint shown after listing available L commands.
47             #pod
48             #pod =head2 message
49             #pod
50             #pod my $msg = $command->message;
51             #pod $command = $command->message('Bar');
52             #pod
53             #pod Short usage message shown before listing available L commands.
54             #pod
55             #pod =head2 namespaces
56             #pod
57             #pod my $namespaces = $command->namespaces;
58             #pod $command = $command->namespaces(['MyApp::Command::kevin']);
59             #pod
60             #pod Namespaces to search for available alternative L commands, defaults to
61             #pod L.
62             #pod
63             #pod =head1 METHODS
64             #pod
65             #pod L inherits all methods from L
66             #pod and implements the following new ones.
67             #pod
68             #pod =head2 help
69             #pod
70             #pod $command->help('app');
71             #pod
72             #pod Print usage information for alternative L command.
73             #pod
74             #pod =head1 SEE ALSO
75             #pod
76             #pod L, L, L.
77             #pod
78             #pod =cut
79              
80             __END__