diff hal_halRemoveGenome.xml @ 0:f5f265415faa draft default tip

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/main/tools/haltools commit 6244b9d15a5ad97ae20191e2f8fbafe2050c3cac
author iuc
date Fri, 06 Feb 2026 10:37:54 +0000
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/hal_halRemoveGenome.xml	Fri Feb 06 10:37:54 2026 +0000
@@ -0,0 +1,72 @@
+<tool id="hal_halremovegenome" name="halRemoveGenome" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="@PROFILE@">
+    <description>removes a leaf genome in a HAL file</description>
+    <macros>
+        <import>macros.xml</import>
+    </macros>
+    <expand macro="requirements"/> 
+    <expand macro="stdio"/>
+    <command detect_errors="aggressive"><![CDATA[
+        ## Copy input HAL to ensure that it is not modified.
+        cp '$input_hal' writable_hal.hal && 
+        halRemoveGenome
+            $noMarkAncestors
+            writable_hal.hal '$deleteNode' &&
+        ## echo 'ok' to check it with assert_stdout. This is needed because there is no other stdout output, 
+        ## and the output HAL file checksum always changes even with identical inputs.
+        echo 'ok'
+    ]]></command>
+    <inputs>
+        <expand macro="input_hal"/>
+        <param name="deleteNode" type="text" value="" label="Node name" help="Leaf genome to remove from tree">
+            <expand macro="sanitizer_default"/>
+            <expand macro="validator_trim"/>
+        </param>
+        <expand macro="params_noMarkAncestors"/>
+    </inputs>
+    <outputs>
+        <data name="out_file" format="hal" label="${tool.name} on ${on_string}" from_work_dir="writable_hal.hal"/>
+    </outputs>
+    <tests>
+        <test expect_num_outputs="1">
+            <param name="input_hal" value="halTest.hal"/>
+            <param name="deleteNode" value="Genome_1"/>
+            <output name="out_file" ftype="hal">
+                <assert_contents>
+                    <has_size min="50000"/>
+                </assert_contents>
+            </output>
+            <assert_stdout>
+                <has_line line="ok"/>
+            </assert_stdout>
+        </test>
+        <test expect_num_outputs="1">
+            <param name="input_hal" value="halTest.hal"/>
+            <param name="deleteNode" value="Genome_1"/>
+            <param name="noMarkAncestors" value="true"/>
+            <output name="out_file" ftype="hal">
+                <assert_contents>
+                    <has_size min="50000"/>
+                </assert_contents>
+            </output>
+            <assert_stdout>
+                <has_line line="ok"/>
+            </assert_stdout>
+        </test>
+    </tests>
+    <help><![CDATA[
+halRemoveGenome removes a specified leaf genome from the input HAL file and updates the tree structure accordingly. 
+By default, ancestor nodes are marked for update to ensure consistency of the alignment after removal. 
+This behavior can be disabled when ancestor updates are not required.
+
+A new HAL file is created as output instead of modifying the input HAL file.
+
+-----
+
+.. class:: warningmark
+
+Running the tool on a HAL file in mmap format will fail because this format type is not supported by this tool.
+It is recommended to convert the input to HDF5 format first using halExtract.
+    ]]></help>
+    <expand macro="citation"/>
+    <expand macro="creator"/>
+</tool>
\ No newline at end of file