| 1 | package App::lcpan::Cmd::mentions_for_script; | ||
| 2 | |||
| 3 | 1 | ▶ | use 5.010; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | 1 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | 1 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | 1 | ▶ | use Log::ger; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | 1 | require App::lcpan; | |
| 9 | 1 | require App::lcpan::Cmd::mentions; | |
| 10 | |||
| 11 | 1 | our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY | |
| 12 | 1 | our $DATE = '2023-09-26'; # DATE | |
| 13 | 1 | our $DIST = 'App-lcpan'; # DIST | |
| 14 | 1 | our $VERSION = '1.074'; # VERSION | |
| 15 | |||
| 16 | 1 | our %SPEC; | |
| 17 | |||
| 18 | 1 | my $mentions_args = $App::lcpan::Cmd::mentions::SPEC{handle_cmd}{args}; | |
| 19 | |||
| 20 | $SPEC{'handle_cmd'} = { | ||
| 21 | v => 1.1, | ||
| 22 | summary => 'List POD mentions for script(s)', | ||
| 23 | description => <<'_', | ||
| 24 | |||
| 25 | This subcommand is a shortcut for: | ||
| 26 | |||
| 27 | % lcpan mentions --type script --mentioned-script SCRIPT | ||
| 28 | |||
| 29 | _ | ||
| 30 | args => { | ||
| 31 | %App::lcpan::common_args, | ||
| 32 | %App::lcpan::scripts_args, | ||
| 33 | 18 | (map {$_ => $mentions_args->{$_}} | |
| 34 | 1 | grep {!/\A(type|mentioned_modules|mentioned_scripts)\z/} | |
| 35 | keys %$mentions_args), | ||
| 36 | }, | ||
| 37 | }; | ||
| 38 | 0 | ▶ | sub handle_cmd { |
|
Subroutine
handle_cmd: not called CC=1 SCAR=6.9
Pod
documented
| |||
| 39 | 0 | my %args = @_; | |
| 40 | |||
| 41 | 0 | my %mentions_args = %args; | |
| 42 | |||
| 43 | 0 | delete $mentions_args{scripts}; | |
| 44 | 0 | $mentions_args{mentioned_scripts} = $args{scripts}; | |
| 45 | |||
| 46 | 0 | $mentions_args{type} = 'script'; | |
| 47 | |||
| 48 | 0 | App::lcpan::Cmd::mentions::handle_cmd(%mentions_args); | |
| 49 | } | ||
| 50 | |||
| 51 | 1 | 1; | |
| 52 | # ABSTRACT: List POD mentions for script(s) | ||
| 53 | |||
| 54 | __END__ | ||