| 1 | #!/usr/bin/env perl | ||||||||||||
| 2 | # pmcat -- page a module file | ||||||||||||
| 3 | |||||||||||||
| 4 | # ------ pragmas | ||||||||||||
| 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 | our $VERSION = '2.0.0'; | |||||||||||
| 9 | |||||||||||||
| 10 | # ------ define variables | ||||||||||||
| 11 | 1 | my $pager = undef; # $ENV{PAGER} - output paging program | |||||||||||
| 12 | |||||||||||||
| 13 | 1 | ▶ | BEGIN { $^W = 1 } | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 14 | 1 | ▶ | BEGIN { die "usage: $0 module ...\n" unless @ARGV } | ||||||||||
|
Subroutine
BEGIN: called CC=2 SCAR=7.6
Branch: 1 branch
| |||||||||||||
| 15 | |||||||||||||
| 16 | 1 | ▶ | use FindBin qw($Bin); | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 17 | |||||||||||||
| 18 | 1 | ▶ | unless ($pager = $ENV{PAGER}) { | ||||||||||
|
Branch: 1 branch
| |||||||||||||
| 19 | 1 | require Config; | |||||||||||
| 20 | 1 | ▶ | $pager = $Config::Config{"pager"} || "more"; | ||||||||||
|
Condition50%1/2
$Config::Config{'pager'} || 'more'
MC/DC0%0/1
$Config::Config{'pager'} || 'more'
$Config::Config{'pager'}
Truth table50%1/2
A
A= $Config::Config{'pager'}
| |||||||||||||
| 21 | } | ||||||||||||
| 22 | |||||||||||||
| 23 | 1 | exec "$pager `$^X -S $Bin/pmpath @ARGV`"; | |||||||||||
| 24 | |||||||||||||
| 25 | __END__ | ||||||||||||