diff picard_SortSam.xml @ 33:3f254c5ced1d draft default tip

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/picard commit 9ecbbb878d68a980ba35a90865e524c723ca3ed8
author iuc
date Sun, 03 Mar 2024 16:06:11 +0000
parents f9242e01365a
children
line wrap: on
line diff
--- a/picard_SortSam.xml	Mon Sep 25 08:32:17 2023 +0000
+++ b/picard_SortSam.xml	Sun Mar 03 16:06:11 2024 +0000
@@ -1,49 +1,44 @@
-<tool id="picard_SortSam" name="SortSam" version="@TOOL_VERSION@.@WRAPPER_VERSION@">
-  <description>sort SAM/BAM dataset</description>
-  <macros>
-    <import>picard_macros.xml</import>
-    <token name="@WRAPPER_VERSION@">1</token>
-  </macros>
-  <expand macro="requirements" />
-  <command detect_errors="exit_code"><![CDATA[
+<tool id="picard_SortSam" name="SortSam" version="@TOOL_VERSION@.@WRAPPER_VERSION@" profile="@PROFILE@">
+    <description>sort SAM/BAM dataset</description>
+    <macros>
+        <import>picard_macros.xml</import>
+        <token name="@WRAPPER_VERSION@">0</token>
+    </macros>
+    <expand macro="requirements"/>
+    <command detect_errors="exit_code"><![CDATA[
     #if $sort_order == "queryname":
         #set $output = "output.sam"
-        ln -s '${outFile}' output.sam &&
+        ln -sf '${outFile}' output.sam &&
     #else:
         #set $output = $outFile
     #end if
     @java_options@
     @symlink_element_identifier@
-    picard
-    SortSam
-    INPUT='$escaped_element_identifier'
-    OUTPUT='${output}'
-    SORT_ORDER="${sort_order}"
-    QUIET=true
-    VERBOSITY=ERROR
-    VALIDATION_STRINGENCY=${validation_stringency}
+    picard SortSam
+    --INPUT '$escaped_element_identifier'
+    --OUTPUT '${output}'
+    --SORT_ORDER '${sort_order}'
+    --QUIET true
+    --VERBOSITY ERROR
+    --VALIDATION_STRINGENCY ${validation_stringency}
   ]]></command>
-
-  <inputs>
-    <param name="inputFile" type="data" format="sam,bam" label="Select SAM/BAM dataset or dataset collection" help="If empty, upload or import a SAM/BAM dataset"/>
-    <param name="sort_order" type="select" display="radio" label="Sort order" help="SORT_ORDER; default=coordinate. Selecting Queryname will output SAM file, as Galaxy does not support BAM files that are not coordinate sorted.">
-      <option value="coordinate" selected="True">Coordinate</option>
-      <option value="queryname">Queryname</option>
-    </param>
-    <expand macro="VS" />
-  </inputs>
-
-  <outputs>
-      <data name="outFile" format="bam" label="${tool.name} on ${on_string}: Alignment sorted in ${sort_order} order">
-          <change_format>
-              <when input="sort_order" value="queryname" format="sam"/>
-          </change_format>
-    </data>
-  </outputs>
-
-
-  <tests>
-      <!-- This test fails when setting metadata on non-coordinate sorted bam files.
+    <inputs>
+        <param name="inputFile" type="data" format="sam,bam" label="Select SAM/BAM dataset or dataset collection" help="If empty, upload or import a SAM/BAM dataset"/>
+        <param name="sort_order" type="select" display="radio" label="Sort order" help="SORT_ORDER; default=coordinate. Selecting Queryname will output SAM file, as Galaxy does not support BAM files that are not coordinate sorted.">
+            <option value="coordinate" selected="True">Coordinate</option>
+            <option value="queryname">Queryname</option>
+        </param>
+        <expand macro="VS"/>
+    </inputs>
+    <outputs>
+        <data name="outFile" format="bam" label="${tool.name} on ${on_string}: Alignment sorted in ${sort_order} order">
+            <change_format>
+                <when input="sort_order" value="queryname" format="sam"/>
+            </change_format>
+        </data>
+    </outputs>
+    <tests>
+        <!-- This test fails when setting metadata on non-coordinate sorted bam files.
            This should be handled better in Galaxy (info as of release 16.0).
            Workaroudn is to produce queryname sorted sam files.
     <test>
@@ -52,19 +47,18 @@
       <output name="outFile" file="picard_SortSam_test1.bam" ftype="bam" lines_diff="4"/>
     </test>
   -->
-    <test>
-      <param name="inputFile" ftype="bam" value="picard_SortSam.bam" />
-      <param name="sort_order" value="queryname"/>
-      <output name="outFile" file="picard_SortSam_test1.sam" ftype="sam" lines_diff="4" compare="contains"/>
-    </test>
-    <test>
-      <param name="inputFile" ftype="bam" value="picard_SortSam.bam" />
-      <param name="sort_order" value="coordinate"/>
-      <output name="outFile" file="picard_SortSam_test1.bam" ftype="bam" lines_diff="4"/>
-    </test>
-  </tests>
-
-  <help>
+        <test>
+            <param name="inputFile" ftype="bam" value="picard_SortSam.bam"/>
+            <param name="sort_order" value="queryname"/>
+            <output name="outFile" file="picard_SortSam_test1.sam" ftype="sam" lines_diff="4" compare="contains"/>
+        </test>
+        <test>
+            <param name="inputFile" ftype="bam" value="picard_SortSam.bam"/>
+            <param name="sort_order" value="coordinate"/>
+            <output name="outFile" file="picard_SortSam_test1.bam" ftype="bam" lines_diff="4"/>
+        </test>
+    </tests>
+    <help>
 
 .. class:: infomark
 
@@ -82,5 +76,5 @@
  @more_info@
 
   </help>
-  <expand macro="citations" />
+    <expand macro="citations"/>
 </tool>