diff lastal.xml @ 4:8705e0d74a0f draft

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/last commit 6b601baaf89634bc8d110ea06e3e64c7a585f3ba"
author iuc
date Wed, 24 Mar 2021 22:36:50 +0000
parents bf30030e5265
children 19c265784f35
line wrap: on
line diff
--- a/lastal.xml	Fri Nov 13 09:05:49 2020 +0000
+++ b/lastal.xml	Wed Mar 24 22:36:50 2021 +0000
@@ -1,4 +1,4 @@
-<tool id="last_al" name="LASTal" version="@LAST_CONDA_VERSION@+galaxy1" profile="18.01">
+<tool id="last_al" name="LASTal" version="@LAST_CONDA_VERSION@+galaxy0" profile="20.01">
 
     <description>finds local alignments between query sequences, and reference sequences.</description>
 
@@ -11,21 +11,28 @@
     </requirements>
 
     <command detect_errors="exit_code"><![CDATA[
+        set -e -o pipefail; 
+
         #if $db_opts.db_opts_input == 'lastdb'
             ln -s '$db_opts.lastdatabase.extra_files_path' './db_files' &&
         #end if
-        
-        lastal
 
-        #if $query_seq.ext == 'fasta'
+        #if $query_seq.ext.endswith('.gz')
+        zcat 
+        #else
+        cat 
+        #end if
+        '$query_seq' | lastal
+
+        #if $query_seq.ext.startswith('fasta')
             -Q 0
-        #else if $query_seq.ext == 'fastqsanger'
+        #else if $query_seq.ext.startswith('fastqsanger')
             -Q 1
-        #else if $query_seq.ext == 'fastqsolexa'
+        #else if $query_seq.ext.startswith('fastqsolexa')
             -Q 2
-        #else if $query_seq.ext == 'fastqillumina'
+        #else if $query_seq.ext.startswith('fastqillumina')
             -Q 3
-        #else if $query_seq.ext == 'pssm'
+        #else if $query_seq.ext.startswith('pssm')
             -Q 5            
         #end if
 
@@ -79,14 +86,12 @@
             'db_files/lastdb'
         #end if
 
-        '$query_seq'
-
         >'$outfile'
     ]]></command>
 
     <inputs>
         <expand macro="input_db"/>
-        <param name="query_seq" type="data" format="fasta,fastqsanger,fastqsolexa,fastqillumina,tabular" label="Query sequences"/>
+        <param name="query_seq" type="data" format="fasta,fasta.gz,fastq,fastq.gz,tabular" label="Query sequences"/>
 
         <section name="lastal" title="Lastal arguments" expanded="true">
             <param argument="-f" type="select" multiple="false" label="Output format">
@@ -348,7 +353,7 @@
                 <param name="db_opts_input" value="db"/>
                 <param name="database" value="humdb"/>
             </conditional>
-            <param name="query_seq" value="fuguMito.fa" ftype="fasta"/>
+            <param name="query_seq" value="fuguMito.fa.gz" ftype="fasta.gz"/>
             <output name="outfile" ftype="maf" file="last_align_gen.maf" lines_diff="2"/>
         </test>
         <test>
@@ -369,7 +374,7 @@
                 <param name="db_opts_input" value="db"/>
                 <param name="database" value="humdb-sanger"/>
             </conditional>
-            <param name="query_seq" value="fuguMito.fq" ftype="fastqsanger"/>
+            <param name="query_seq" value="fuguMito.fq.gz" ftype="fastqsanger.gz"/>
             <section name="lastal">
                 <param name="Q" value="1"/>
             </section>