bin/seqtrimnext in seqtrimnext-2.0.59 vs bin/seqtrimnext in seqtrimnext-2.0.60

- old
+ new

@@ -117,11 +117,11 @@ #Checks install requeriments require 'install_requirements' ins = InstallRequirements.new if (!ins.check_install_requirements) - exit + exit(-1) end require "logger" require 'optparse' require "global_match" @@ -376,11 +376,11 @@ exit end if !File.exists?($FORMATTED_DB_PATH) STDERR.puts "Database path not found: #{$FORMATTED_DB_PATH}. \n\n\nInstall databases to this path or set your BLASTDB environment variable (eg.: export BLASTDB=new_path)" - exit + exit(-1) end if options[:check_db] then # check and format blast databases @@ -393,21 +393,21 @@ # if ((ARGV.count != 2) && (ARGV.count != 3)) # con esto vemos si hay argumentos, if (ARGV.count != 0) || (!required_options) # con esto vemos si hay argumentos, puts "You must provide all required options" puts "" puts optparse.help - exit + exit(-1) end # check for template if (!File.exists?(options[:template])) if File.exists?(File.join($SEQTRIM_PATH,'templates',options[:template])) options[:template] = File.join($SEQTRIM_PATH,'templates',options[:template]) else $LOG.info "Params file: #{options[:template]} doesn't exists. \n\nYou can use your own template or specify one from this list:\n=============================" puts Dir.glob(File.join($SEQTRIM_PATH,'templates','*.txt')).map{|t| File.basename(t)} - exit + exit(-1) end end $LOG.info "Using init file: #{$SEQTRIMNEXT_INIT}" $LOG.info "Using params file: #{options[:template]}" @@ -416,24 +416,24 @@ if options[:fastq] options[:fastq].each do |fastq_file| # fastq file if (!fastq_file.nil? && fastq_file!='-' && !File.exists?(File.expand_path(fastq_file))) $LOG.error "Input file: #{fastq_file} doesn't exists" - exit + exit(-1) end end end # fasta file if (!options[:fasta].nil? && !File.exists?(options[:fasta])) $LOG.error "Input file: #{options[:fasta]} doesn't exists" - exit + exit(-1) end # qual file if ((!options[:qual].nil?)&&(!File.exists?(options[:qual]))) $LOG.error "Input file: #{options[:qual]} doesn't exists" - exit + exit(-1) end s = Seqtrim.new(options) #generate report