bin/stow | |||
---|---|---|---|
Criterion | Covered | Total | % |
branch | 31 | 52 | 59.6 |
line | true | false | branch |
---|---|---|---|
482 | 0 | 0 | if (%conflicts) { } |
484 | 0 | 0 | unless $conflicts{$action} |
497 | 0 | 0 | if ($options->{'simulate'}) |
535 | 1 | 9 | if (defined $type and $type eq 'ARRAY' and defined $rc_value) { } |
608 | 2 | 19 | if ($action eq 'restow') { } |
3 | 16 | elsif ($action eq 'unstow') { } | |
619 | 0 | 30 | unless &GetOptionsFromArray(\@_, \%options, 'verbose|v:+', 'help|h', 'simulate|n|no', 'version|V', 'compat|p', 'dir|d=s', 'target|t=s', 'adopt', 'no-folding', 'dotfiles', 'ignore=s', sub { my $regex = $_[1]; push @{$options{'ignore'};}, qr/$regex\z/; } , 'override=s', sub { my $regex = $_[1]; push @{$options{'override'};}, qr/\A$regex/; } , 'defer=s', sub { my $regex = $_[1]; push @{$options{'defer'};}, qr/\A$regex/; } , 'D|delete', sub { $action = 'unstow'; } , 'S|stow', sub { $action = 'stow'; } , 'R|restow', sub { $action = 'restow'; } , '<>', sub { if ($action eq 'restow') { push @pkgs_to_unstow, $_[0]; push @pkgs_to_stow, $_[0]; } elsif ($action eq 'unstow') { push @pkgs_to_unstow, $_[0]; } else { push @pkgs_to_stow, $_[0]; }; } ) |
621 | 0 | 30 | if $options{'help'} |
622 | 0 | 30 | if $options{'version'} |
630 | 7 | 7 | unless (exists $options->{'dir'}) |
631 | 0 | 7 | length $ENV{'STOW_DIR'} ? : |
635 | 0 | 14 | unless -d $options->{'dir'} |
637 | 7 | 7 | if (exists $options->{'target'}) { } |
639 | 0 | 7 | unless -d $options->{'target'} |
649 | 0 | 13 | unless (@$pkgs_to_stow or @$pkgs_to_unstow) |
656 | 0 | 23 | if ($package =~ m[/]) |
676 | 14 | 2 | if (defined $ENV{'HOME'}) |
680 | 10 | 20 | if (-r $file) |
681 | 0 | 10 | unless open my $FILE, '<', $file |
687 | 0 | 10 | unless close $FILE |
695 | 7 | 9 | if (exists $rc_options->{'target'}) |
699 | 8 | 8 | if (exists $rc_options->{'dir'}) |
755 | 2 | 5 | unless (exists $ENV{$var}) |
776 | 0 | 3 | $1 ? : |
796 | 0 | 0 | if ($msg) |
835 | 0 | 0 | exit defined $msg ? : |