Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix dependancy checking option #382

Merged
merged 3 commits into from
Jan 16, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,14 +109,14 @@ bedtools cd-hit blast mcl GNUparallel prank mafft fasttree
```

## Ancient systems and versions of perl
The code will not work with perl 5.8 or below (pre-modern perl). We no longer test against 5.10 (released 2007). If you're running a very old verison of Linux, you're also in trouble.
The code will not work with perl 5.8 or below (pre-modern perl). We no longer test against 5.10 (released 2007) or 5.12 (released 2010). If you're running a very old verison of Linux, you're also in trouble.

# Versions of software we test against
* Perl 5.14, 5.16, 5.20, 5.24
* cdhit 4.6.1
* ncbi blast+ 2.4.0
* Perl 5.14, 5.26
* cdhit 4.6.8
* ncbi blast+ 2.6.0
* mcl 14-137
* bedtools 2.27.1
* prank 130410
* GNU parallel 20130922, 20160722, 20150122
* prank 140603
* GNU parallel 20170822, 20160722
* FastTree 2.1.9
2 changes: 1 addition & 1 deletion dist.ini
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ author = Andrew J. Page <ap13@sanger.ac.uk>
license = GPL_3
copyright_holder = Wellcome Trust Sanger Institute
copyright_year = 2013
version = 3.11.3
version = 3.11.4
main_module = lib/Bio/Roary.pm

[MetaResources]
Expand Down
21 changes: 14 additions & 7 deletions lib/Bio/Roary/CommandLine/Roary.pm
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ has 'cpus' => ( is => 'rw', isa => 'Int', default => 1 );
has 'output_multifasta_files' => ( is => 'rw', isa => 'Bool', default => 0 );
has 'perc_identity' => ( is => 'rw', isa => 'Num', default => 95 );
has 'dont_delete_files' => ( is => 'rw', isa => 'Bool', default => 0 );
has 'check_dependancies' => ( is => 'rw', isa => 'Bool', default => 0 );
has 'dont_create_rplots' => ( is => 'rw', isa => 'Bool', default => 1 );
has 'dont_run_qc' => ( is => 'rw', isa => 'Bool', default => 0 );
has 'dont_split_groups' => ( is => 'rw', isa => 'Bool', default => 0 );
Expand Down Expand Up @@ -126,16 +127,22 @@ sub BUILD {
print $self->usage_text;
return;
}

if ( defined($verbose) ) {
$self->verbose($verbose);
$self->logger->level(10000);
}

if ($check_dependancies) {
$self->check_dependancies($check_dependancies) if ( defined($check_dependancies) );
if ($self->check_dependancies) {
my $check_tools = Bio::Roary::External::CheckTools->new();
$check_tools->check_all_tools;
$self->logger->error( "Roary version " . $self->_version() );
}

if ( defined($verbose) ) {
$self->verbose($verbose);
$self->logger->level(10000);
if( @{ $self->args } < 1 )
{
return;
}
}

if ( @{ $self->args } < 2 ) {
Expand Down Expand Up @@ -260,7 +267,7 @@ sub _setup_output_directory {
sub run {
my ($self) = @_;

return if($self->version || $self->help);
return if($self->version || $self->help || ($self->check_dependancies && @{$self->fasta_files} < 1) );

$self->_setup_output_directory;

Expand Down