| 1 | package BioX::Workflow::Plugin::FileDetails; | ||||||||||
| 2 | |||||||||||
| 3 | 1 | our $VERSION = '0.11'; | |||||||||
| 4 | |||||||||||
| 5 | 1 | ▶ | use Moose::Role; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | 1 | ▶ | use List::Uniq ':all'; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 7 | 1 | ▶ | use Data::Dumper; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 8 | |||||||||||
| 9 | has 'collect_outdirs' => ( | ||||||||||
| 10 | traits => ['Array'], | ||||||||||
| 11 | is => 'rw', | ||||||||||
| 12 | isa => 'ArrayRef', | ||||||||||
| 13 | 0 | ▶ | default => sub {[]}, | ||||||||
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||||||||||
| 14 | 1 | handles => { | |||||||||
| 15 | add_collect_outdirs => 'push', | ||||||||||
| 16 | has_collect_outdirs => 'count', | ||||||||||
| 17 | }, | ||||||||||
| 18 | ); | ||||||||||
| 19 | |||||||||||
| 20 | 0 | ▶ | after 'process_template' => sub { | ||||||||
|
Subroutine
__ANON__: not called CC=2 SCAR=17.9
| |||||||||||
| 21 | 0 | my $self = shift; | |||||||||
| 22 | 0 | my $data = shift; | |||||||||
| 23 | |||||||||||
| 24 | 0 | $self->add_collect_outdirs($self->outdir); | |||||||||
| 25 | 0 | $self->add_collect_outdirs($self->indir); | |||||||||
| 26 | |||||||||||
| 27 | 0 | ▶ | @{$self->collect_outdirs} = uniq(@{$self->collect_outdirs}) if $self->has_collect_outdirs; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 28 | 1 | }; | |||||||||
| 29 | |||||||||||
| 30 | 0 | ▶ | after 'write_pipeline' => sub { | ||||||||
|
Subroutine
__ANON__: not called CC=2 SCAR=17.9
| |||||||||||
| 31 | 0 | my $self = shift; | |||||||||
| 32 | |||||||||||
| 33 | 0 | print <<EOF; | |||||||||
| 34 | |||||||||||
| 35 | # | ||||||||||
| 36 | # Starting FileDetails Plugin | ||||||||||
| 37 | # | ||||||||||
| 38 | |||||||||||
| 39 | EOF | ||||||||||
| 40 | 0 | foreach my $outdir (@{$self->collect_outdirs}){ | |||||||||
| 41 | 0 | my $cmd = "filedetails.pl --check_dir ".$outdir; | |||||||||
| 42 | 0 | print "\n"; | |||||||||
| 43 | 0 | print "filedetails.pl --check_dir ".$outdir; | |||||||||
| 44 | 0 | print "\n\n"; | |||||||||
| 45 | } | ||||||||||
| 46 | |||||||||||
| 47 | 0 | print <<EOF; | |||||||||
| 48 | |||||||||||
| 49 | # | ||||||||||
| 50 | # Ending FileDetails Plugin | ||||||||||
| 51 | # | ||||||||||
| 52 | EOF | ||||||||||
| 53 | |||||||||||
| 54 | 1 | }; | |||||||||
| 55 | |||||||||||
| 56 | 1 | 1; | |||||||||
| 57 | __END__ | ||||||||||