| 1 | package App::Pinto::Command::roots; | ||||||||||
| 2 | |||||||||||
| 3 | # ABSTRACT: show the roots of a stack | ||||||||||
| 4 | |||||||||||
| 5 | 1 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | 1 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 7 | |||||||||||
| 8 | 1 | ▶ | use Pinto::Util qw(interpolate); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 9 | |||||||||||
| 10 | #----------------------------------------------------------------------------- | ||||||||||
| 11 | |||||||||||
| 12 | 1 | ▶ | use base 'App::Pinto::Command'; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 13 | |||||||||||
| 14 | #------------------------------------------------------------------------------ | ||||||||||
| 15 | |||||||||||
| 16 | 1 | our $VERSION = '0.14'; # VERSION | |||||||||
| 17 | |||||||||||
| 18 | #------------------------------------------------------------------------------ | ||||||||||
| 19 | |||||||||||
| 20 | 0 | ▶ | sub command_names { return qw( roots ) } | ||||||||
|
Subroutine
command_names: not called CC=1 SCAR=6.9
Pod
documented
| |||||||||||
| 21 | |||||||||||
| 22 | #------------------------------------------------------------------------------ | ||||||||||
| 23 | |||||||||||
| 24 | 0 | ▶ | sub opt_spec { | ||||||||
|
Subroutine
opt_spec: not called CC=1 SCAR=6.9
Pod
documented
| |||||||||||
| 25 | 0 | my ( $self, $app ) = @_; | |||||||||
| 26 | |||||||||||
| 27 | return ( | ||||||||||
| 28 | 0 | [ 'format=s' => 'Format specification (See POD for details)' ], | |||||||||
| 29 | [ 'stack|s=s' => 'Show roots of this stack' ], | ||||||||||
| 30 | ); | ||||||||||
| 31 | } | ||||||||||
| 32 | |||||||||||
| 33 | #------------------------------------------------------------------------------ | ||||||||||
| 34 | |||||||||||
| 35 | 0 | ▶ | sub validate_args { | ||||||||
|
Subroutine
validate_args: not called CC=4 SCAR=30.0
Pod
documented
| |||||||||||
| 36 | 0 | my ( $self, $opts, $args ) = @_; | |||||||||
| 37 | |||||||||||
| 38 | $self->usage_error('Multiple arguments are not allowed') | ||||||||||
| 39 | 0 | ▶ | if @{$args} > 1; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 40 | |||||||||||
| 41 | $opts->{format} = interpolate( $opts->{format} ) | ||||||||||
| 42 | 0 | ▶ | if exists $opts->{format}; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 43 | |||||||||||
| 44 | 0 | ▶ | $opts->{stack} = $args->[0] | ||||||||
|
Branch: 1 branch
| |||||||||||
| 45 | if $args->[0]; | ||||||||||
| 46 | |||||||||||
| 47 | 0 | return 1; | |||||||||
| 48 | } | ||||||||||
| 49 | |||||||||||
| 50 | #------------------------------------------------------------------------------ | ||||||||||
| 51 | |||||||||||
| 52 | 1 | 1; | |||||||||
| 53 | |||||||||||
| 54 | __END__ | ||||||||||