File Coverage

blib/lib/Banal/Dist/Util.pm
Criterion Covered Total %
statement 20 25 80.0
branch 0 2 0.0
condition 0 2 0.0
subroutine 7 8 87.5
pod 0 1 0.0
total 27 38 71.0


line stmt bran cond sub pod time code
1 1     1   4279 use 5.014; # because we use the 'state' and 'non-destructive substitution' feature (s///r)
  1         26  
2 1     1   20 use strict;
  1         12  
  1         60  
3 1     1   14 use warnings;
  1         2  
  1         148  
4              
5             package Banal::Dist::Util; # git description: v0.004-4-g1789484
6             # vim: set ts=2 sts=2 sw=2 tw=115 et :
7             # ABSTRACT: General purpose utility collection mainly used by C
8             # KEYWORDS: author utility
9              
10             our $VERSION = '0.005';
11             # AUTHORITY
12              
13              
14 1     1   933 use Path::Tiny qw(path);
  1         12698  
  1         103  
15 1     1   735 use Data::Printer; # DEBUG aid.
  1         40836  
  1         7  
16              
17 1     1   617 use Exporter::Shiny qw( pause_config );
  1         4070  
  1         15  
18              
19 1     1   580 use namespace::autoclean;
  1         14786  
  1         4  
20              
21              
22             # return username, password from ~/.pause
23             sub pause_config_alt # Hmmm. We've got a similar named routine in *::Pause.pm
24             {
25 0   0 0 0   my $file = path($ENV{HOME} // 'oops', '.pause');
26 0 0         return if not -e $file;
27              
28             my ($username, $password) = map {
29 0           my (undef, $val) = split ' ', $_; $val # awk-style whitespace splitting
  0            
  0            
30             } $file->lines;
31             }
32              
33              
34              
35              
36              
37              
38              
39             1;
40              
41             __END__