changeset 2:1f1738444233 draft default tip

planemo upload for repository https://github.com/katholt/srst2 commit 90275e51aa271edacdd9d277c441e38e99502c53
author iuc
date Mon, 28 Oct 2024 13:08:41 +0000
parents 4e0b819bf73e
children
files macros.xml srst2.xml
diffstat 2 files changed, 30 insertions(+), 20 deletions(-) [+]
line wrap: on
line diff
--- a/macros.xml	Tue Sep 06 14:17:01 2022 +0000
+++ b/macros.xml	Mon Oct 28 13:08:41 2024 +0000
@@ -1,7 +1,7 @@
 <?xml version="1.0"?>
 <macros>
     <token name="@TOOL_VERSION@">0.2.0</token>
-    <token name="@VERSION_SUFFIX@">1</token>
+    <token name="@VERSION_SUFFIX@">2</token>
     <token name="@PROFILE@">20.01</token>
     <xml name="requirements">
         <requirements>
@@ -10,10 +10,15 @@
             <yield/>
         </requirements>
     </xml>
+    <xml name="xrefs">
+        <xrefs>
+            <xref type="bio.tools">srst2</xref>
+        </xrefs>
+    </xml>
     <xml name="read_type_options">
         <param argument="--read_type" type="select" label="Read file type">
             <option value="q" selected="true">fastq</option>
             <option value="f">fasta</option>
         </param>
     </xml>
-</macros>
\ No newline at end of file
+</macros>
--- a/srst2.xml	Tue Sep 06 14:17:01 2022 +0000
+++ b/srst2.xml	Mon Oct 28 13:08:41 2024 +0000
@@ -4,6 +4,7 @@
         <import>macros.xml</import>
         <token name="@FAST_A_Q_FORMATS@">fasta,fasta.gz,fastq,fastq.gz,fastqsanger,fastqsanger.gz</token>
     </macros>
+    <expand macro="xrefs"/>
     <expand macro="requirements"/>
     <version_command>srst2 --version</version_command>
     <command detect_errors="exit_code"><![CDATA[
@@ -102,9 +103,11 @@
 #if 'report_new_consensus' in str($output_files_selector) and $use_gene_db.selector == "yes" and $use_mlst_db.selector == "yes"
 && mkdir -p allelesOutput/ && cp *.output__input.*.pileup allelesOutput | true
 #end if
+
 #if $use_gene_db.selector == "yes" and  $use_gene_db.no_gene_details
-&& mkdir -p geneTypingOutput/ && cp output__genes__*__results.txt geneTypingOutput | true && cp output__fullgenes__*__results.txt geneTypingOutput | true
+&& mkdir -p geneTypingOutput/ geneTypingOutputFull/ && cp output__genes__*__results.txt geneTypingOutput | true && cp output__fullgenes__*__results.txt geneTypingOutputFull | true
 #end if
+
 #if 'save_scores' in str($output_files_selector)
     && mkdir -p scoresOutput/ && cp *.scores scoresOutput | true
 #end if
@@ -153,7 +156,7 @@
                             <add value="_" />    
                         </valid>
                     </sanitizer>
-                    <validator type="regex">[A-Za-z0-9 =-_/+]+</validator>
+                    <validator type="regex">[A-Za-z0-9 =_/+-]+</validator>
                 </param>
                 <param argument="--mlst_max_mismatch" type="integer" value="10" label="Maximum number of mismatches per read for MLST allele calling"/>
                 <param argument="--min_depth" type="integer" value="5" label="Minimum mean depth to flag as dubious allele call"/>
@@ -197,7 +200,11 @@
             <filter>use_mlst_db['selector'] == "yes"</filter>
         </data>  
         <collection name="gene_typing" type="list" label="${tool.name} on ${on_string}: Gene typing results files" >
-            <discover_datasets pattern="(?P&lt;designation&gt;.+)" directory="geneTypingOutput" format="txt,tabular"/>
+            <discover_datasets pattern="(?P&lt;designation&gt;.+)" directory="geneTypingOutput" format="tabular"/>
+            <filter>use_gene_db['selector'] == "yes" and use_gene_db['no_gene_details'] is True</filter>
+        </collection>         
+        <collection name="gene_typing_full" type="list" label="${tool.name} on ${on_string}: Full Gene typing results files" >
+            <discover_datasets pattern="(?P&lt;designation&gt;.+)" directory="geneTypingOutputFull" format="tabular"/>
             <filter>use_gene_db['selector'] == "yes" and use_gene_db['no_gene_details'] is True</filter>
         </collection>         
         <data name="Compiled_gene_and_mlst_output" format="tabular" from_work_dir="output__compiledResults.txt" label="${tool.name} on ${on_string}: Compiled MLST and Gene databases Results">
@@ -226,7 +233,7 @@
         </data>             
     </outputs>
     <tests>
-    <test expect_num_outputs="9">
+    <test expect_num_outputs="10">
         <param name="prob_err" value="0.01"/>
         <param name="max_unaligned_overlap" value="10"/>
         <param name="mapq" value="1"/>
@@ -263,13 +270,15 @@
             </assert_contents>
         </output>
         <output_collection name="gene_typing" type="list">
-            <element name="output__fullgenes__0-gene_db__results.txt">
+            <element name="output__genes__0-gene_db__results.txt">
                 <assert_contents>
                     <has_text text="AmpC1_Ecoli_Bla"/>
                     <has_n_lines n="2"/>
                 </assert_contents>
             </element>
-            <element name="output__genes__0-gene_db__results.txt">
+        </output_collection>
+        <output_collection name="gene_typing_full" type="list">
+            <element name="output__fullgenes__0-gene_db__results.txt">
                 <assert_contents>
                     <has_text text="AmpC1_Ecoli_Bla"/>
                     <has_n_lines n="2"/>
@@ -288,7 +297,7 @@
                 <has_n_lines n="2"/>
             </assert_contents>
         </output>
-        <output_collection name="new_consensus" type="list">
+        <output_collection name="new_consensus" type="list" count="1">
             <element name="49__AmpC1_Ecoli_Bla__AmpC1__1670.output__input.0-gene_db.pileup">
                 <assert_contents>
                     <has_text text="49__AmpC1_Ecoli_Bla__AmpC1__1670"/>
@@ -296,7 +305,7 @@
                 </assert_contents>
             </element>
         </output_collection>
-        <output_collection name="samtools_pileup_alignment" type="list">
+        <output_collection name="samtools_pileup_alignment" type="list" count="1">
             <element name="output__input.0-gene_db.pileup">
                 <assert_contents>
                     <has_text text="49__AmpC1_Ecoli_Bla__AmpC1__1670"/>
@@ -304,7 +313,7 @@
                 </assert_contents>
             </element>
         </output_collection>
-        <output_collection name="bowtie2_alignment_output" type="list">
+        <output_collection name="bowtie2_alignment_output" type="list" count="1">
             <element name="output__input.0-gene_db.sorted.bam">
                 <assert_contents>
                     <has_size value="18500" delta="1000"/>
@@ -347,14 +356,10 @@
                 <has_size value="0" delta="0"/>
             </assert_contents>
         </output>
-        <output_collection name="new_consensus" type="list">
-        </output_collection>
-        <output_collection name="samtools_pileup_alignment" type="list">
-        </output_collection>
-        <output_collection name="bowtie2_alignment_output" type="list">
-        </output_collection>
-        <output_collection name="scores_ofEachAllele" type="list">
-        </output_collection>
+        <output_collection name="new_consensus" type="list" count="0"/>
+        <output_collection name="samtools_pileup_alignment" type="list" count="0"/>
+        <output_collection name="bowtie2_alignment_output" type="list" count="0"/>
+        <output_collection name="scores_ofEachAllele" type="list" count="0"/>
         <output name="log_output">
             <assert_contents>
                 <has_text text="Total paired readsets found:1"/>
@@ -383,4 +388,4 @@
     <citations>
         <citation type="doi">10.1186/s13073-014-0090-6</citation>
     </citations>
- </tool>
\ No newline at end of file
+ </tool>