bin/seqtrimnext in seqtrimnext-2.0.62 vs bin/seqtrimnext in seqtrimnext-2.0.66
- old
+ new
@@ -214,11 +214,11 @@
else
begin
options[:workers] = Integer(workers)
rescue
STDERR.puts "ERROR:Invalid workers parameter #{options[:workers]}"
- exit
+ exit -1
end
end
end
@@ -266,11 +266,11 @@
options[:format] = nil
opts.on( '-F', '--fastq_quality_format FORMAT', 'Fastq input quality format use sanger or illumina18 for phred+33 based scores. Use illumina15 for phred+64 based scores (default is sanger) file. Use - for <STDIN>' ) do |value|
options[:format] = value
if !['sanger','illumina15', 'illumina18'].include?(value)
STDERR.puts "ERROR: Invalid FASTQ format parameter #{value}"
- exit
+ exit -1
end
end
options[:fasta] = nil
@@ -299,11 +299,11 @@
options[:template] = nil
opts.on( '-t', '--template TEMPLATE_FILE', 'Use TEMPLATE_FILE instead of default parameters' ) do |file|
options[:template] = file
end
- options[:chunk_size] = 100
+ options[:chunk_size] = 5000
opts.on( '-g', '--group_size chunk_size', 'Group sequences in chunks of size <chunk_size>' ) do |cs|
options[:chunk_size] = cs.to_i
end
@@ -330,27 +330,27 @@
# This displays the help screen, all programs are
# assumed to have this option.
opts.on_tail( '-h', '--help', 'Display this screen' ) do
puts opts
show_additional_help
- exit
+ exit -1
end
end
# parse options and remove from ARGV
optparse.parse!
if options[:list_db] then
# List database entries in a database
ListDb.new($DB_PATH,options[:list_db_name])
- exit
+ exit -1
end
if options[:gen_params] then
# Generates a sample params file in current directory
Params.generate_sample_params
- exit
+ exit -1
end
#set logger
# system('rm logs/*')
FileUtils.mkdir('logs') if !File.exists?('logs')
@@ -451,5 +451,7 @@
skip_text=' and remove the -R option from the command line.'
end
$LOG.info "If you want a detailed report in PDF format, be sure you have installed the optional seqtrimnext_report gem (gem install seqtrimnext_report)#{skip_text}"
end
+
+exit(Seqtrim.exit_status)