diff fasterq_dump.xml @ 18:7068f48d0ef9 draft

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/sra-tools commit d22c001db39b52ebaa54837bebe2765c17b5c876"
author iuc
date Mon, 08 Jun 2020 05:49:21 -0400
parents c441583adae5
children 248f85ff0733
line wrap: on
line diff
--- a/fasterq_dump.xml	Wed Apr 29 12:12:23 2020 -0400
+++ b/fasterq_dump.xml	Mon Jun 08 05:49:21 2020 -0400
@@ -1,4 +1,4 @@
-<tool id="fasterq_dump" name="Faster Download and Extract Reads in FASTQ" version="@VERSION@+galaxy2" profile="18.01">
+<tool id="fasterq_dump" name="Faster Download and Extract Reads in FASTQ" version="@VERSION@+galaxy0" profile="18.01">
     <description>format from NCBI SRA</description>
     <macros>
         <import>sra_macros.xml</import>
@@ -6,12 +6,12 @@
     <expand macro="requirements"/>
     <version_command>fasterq-dump --version</version_command>
     <command detect_errors="exit_code"><![CDATA[
+    @COPY_CONFIGFILE@
     @SET_ACCESSIONS@
     #if $input.input_select == "file":
         acc='${input.file.name}' &&
         ln -s '${input.file}' "\$acc" &&
     #end if
-    @CONFIGURE_TIMEOUT@
     @CONFIGURE_RETRY@
     while [ \$SRA_PREFETCH_ATTEMPT -le \$SRA_PREFETCH_RETRIES ] ; do
         fasterq-dump "\$acc" -e \${GALAXY_SLOTS:-1}
@@ -20,7 +20,7 @@
             --min-read-len "$adv.minlen"
         #end if
         $adv.skip_technical >> $log 2>&1 ;
-        if [ \$? == 0 ] ; then
+        if [ \$? == 0 ] && [ \$(ls *.fastq | wc -l) -ge 1 ]; then
             break ;
         else
             echo "Prefetch attempt \$SRA_PREFETCH_ATTEMPT of \$SRA_PREFETCH_RETRIES exited with code \$?" ;
@@ -30,7 +30,7 @@
     done &&
     mkdir -p output &&
     mkdir -p outputOther &&
-    count=`ls *.fastq | wc -l` &&
+    count="\$(ls *.fastq | wc -l)" &&
     echo "There are \$count fastq" &&
     data=(\$(ls *.fastq)) &&
     if [ "\$count" -eq 1 ]; then
@@ -68,6 +68,7 @@
     #end if
     ]]>
     </command>
+    <expand macro="configfile_hack"/>
     <inputs>
         <expand macro="input_conditional"/>
         <section name="adv" title="Advanced Options" expanded="False">
@@ -236,7 +237,7 @@
 .. _fastq-dump: https://ncbi.github.io/sra-tools/fastq-dump.html
 .. _fasterq-dump: https://github.com/ncbi/sra-tools/wiki/HowTo:-fasterq-dump
 .. _collection: https://galaxyproject.org/tutorials/collections/
-.. _link: http://www.ncbi.nlm.nih.gov/Traces/sra/sra.cgi?view=studies
+.. _link: https://trace.ncbi.nlm.nih.gov/Traces/sra/sra.cgi?view=studies
 
 @SRATOOLS_ATTRRIBUTION@