Repository 'bcftools_annotate'
hg clone https://toolshed.g2.bx.psu.edu/repos/iuc/bcftools_annotate

Changeset 24:06eaadeffb7d (2025-12-02)
Previous changeset 23:2c372041ed8c (2024-08-18)
Commit message:
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/main/tools/bcftools commit f6efda26965eb73c9107d367fd5ffdf246ed0dbc
modified:
bcftools_annotate.xml
macros.xml
b
diff -r 2c372041ed8c -r 06eaadeffb7d bcftools_annotate.xml
--- a/bcftools_annotate.xml Sun Aug 18 09:59:56 2024 +0000
+++ b/bcftools_annotate.xml Tue Dec 02 08:19:20 2025 +0000
[
b'@@ -9,7 +9,6 @@\n     <expand macro="requirements" />\n     <expand macro="version_command" />\n     <command detect_errors="aggressive"><![CDATA[\n-@PREPARE_ENV@\n @PREPARE_INPUT_FILE@\n #set $annotation_file = None\n #set $annotation_hdr = None\n@@ -175,7 +174,7 @@\n             <expand macro="macro_include" />\n             <expand macro="macro_exclude" />\n             <expand macro="macro_collapse" />\n-            <expand macro="macro_restrict" />\n+            <expand macro="macro_region_restrict" />\n             <expand macro="macro_samples" />\n         </section>\n         <expand macro="macro_select_output_type" />\n@@ -186,10 +185,14 @@\n     <tests>\n         <test>\n             <param name="input_file" ftype="vcf" value="annotate.vcf" />\n-            <param name="anno_fmt" value="tab" />\n-            <param name="annotations" value="annotate.tab" />\n-            <param name="header_file" value="annotate.hdr" />\n-            <param name="columns" value="CHROM,POS,REF,ALT,ID,QUAL,INFO/T_INT,INFO/T_FLOAT,INDEL" />\n+            <section name="sec_annofile">\n+                <conditional name="annofile">\n+                    <param name="anno_fmt" value="tab" />\n+                    <param name="annotations" value="annotate.tab" />\n+                    <param name="header_file" value="annotate.hdr" />\n+                </conditional>\n+                <param name="columns" value="CHROM,POS,REF,ALT,ID,QUAL,INFO/T_INT,INFO/T_FLOAT,INDEL" />\n+            </section>\n             <param name="output_type" value="v" />\n             <output name="output_file">\n                 <assert_contents>\n@@ -218,9 +221,13 @@\n         </test>\n         <test>\n             <param name="input_file" ftype="vcf" value="annotate.vcf" />\n-            <param name="anno_fmt" value="vcf" />\n-            <param name="annotations" value="annots.vcf" />\n-            <param name="columns" value="STR,ID,QUAL,FILTER" />\n+            <section name="sec_annofile">\n+                <conditional name="annofile">\n+                    <param name="anno_fmt" value="vcf" />\n+                    <param name="annotations" value="annots.vcf" />\n+                </conditional>\n+                <param name="columns" value="STR,ID,QUAL,FILTER" />\n+            </section>\n             <param name="output_type" value="v" />\n             <output name="output_file">\n                 <assert_contents>\n@@ -231,9 +238,13 @@\n         </test>\n         <test>\n             <param name="input_file" ftype="vcf" value="annotate.vcf" />\n-            <param name="anno_fmt" value="vcf" />\n-            <param name="annotations" value="annots.bcf" />\n-            <param name="columns" value="STR,ID,QUAL,FILTER" />\n+            <section name="sec_annofile">\n+                <conditional name="annofile">\n+                    <param name="anno_fmt" value="vcf" />\n+                    <param name="annotations" value="annots.bcf" />\n+                </conditional>\n+                <param name="columns" value="STR,ID,QUAL,FILTER" />\n+            </section>\n             <param name="output_type" value="v" />\n             <output name="output_file">\n                 <assert_contents>\n@@ -244,9 +255,13 @@\n         </test>\n         <test>\n             <param name="input_file" ftype="vcf" value="annotate2.vcf" />\n-            <param name="anno_fmt" value="vcf" />\n-            <param name="annotations" value="annots2.vcf" />\n-            <param name="columns" value="ID,QUAL,FILTER,INFO,FMT" />\n+            <section name="sec_annofile">\n+                <conditional name="annofile">\n+                    <param name="anno_fmt" value="vcf" />\n+                    <param name="annotations" value="annots2.vcf" />\n+                </conditional>\n+                <param name="columns" value="ID,QUAL,FILTER,INFO,FMT" />\n+            </section>\n             <param name="output_type" value="v" />\n             <output name="output_file">\n                 <assert_contents>\n@@ -257,10 +272,16 @@\n         </test>\n         <test>'..b'>\n+                <param name="columns" value="ID,QUAL,FILTER,INFO,FMT" />\n+            </section>\n+            <section name="sec_restrict">\n+                <param name="samples" value="A" />\n+            </section>\n             <param name="output_type" value="v" />\n             <output name="output_file">\n                 <assert_contents>\n@@ -271,8 +292,14 @@\n         </test>\n         <test>\n             <param name="input_file" ftype="vcf" value="annotate3.vcf" />\n-            <param name="anno_fmt" value="none" />\n-            <param name="remove" value="ID,QUAL,^FILTER/fltA,FILTER/fltB,^INFO/AA,INFO/BB,^FMT/GT,FMT/PL" />\n+            <section name="sec_annofile">\n+                <conditional name="annofile">\n+                    <param name="anno_fmt" value="none" />\n+                </conditional>\n+            </section>\n+            <section name="sec_annotate">\n+                <param name="remove" value="ID,QUAL,^FILTER/fltA,FILTER/fltB,^INFO/AA,INFO/BB,^FMT/GT,FMT/PL" />\n+            </section>\n             <param name="output_type" value="v" />\n             <output name="output_file">\n                 <assert_contents>\n@@ -282,8 +309,14 @@\n         </test>\n         <test>\n             <param name="input_file" ftype="vcf" value="annotate3.vcf" />\n-            <param name="anno_fmt" value="none" />\n-            <param name="remove" value="FORMAT" />\n+            <section name="sec_annofile">\n+                <conditional name="annofile">\n+                    <param name="anno_fmt" value="none" />\n+                </conditional>\n+            </section>\n+            <section name="sec_annotate">\n+                <param name="remove" value="FORMAT" />\n+            </section>\n             <param name="output_type" value="v" />\n             <output name="output_file">\n                 <assert_contents>\n@@ -294,11 +327,22 @@\n         <!-- Test region overlap option -->\n         <test>\n             <param name="input_file" ftype="vcf" value="annotate3.vcf" />\n-            <param name="anno_fmt" value="none" />\n-            <param name="remove" value="FORMAT" />\n+            <section name="sec_annofile">\n+                <conditional name="annofile">\n+                    <param name="anno_fmt" value="none" />\n+                </conditional>\n+            </section>\n+            <section name="sec_annotate">\n+                <param name="remove" value="FORMAT" />\n+            </section>\n             <param name="output_type" value="v" />\n             <section name="sec_restrict">\n-                <param name="regions_overlap" value="1"/>\n+                <conditional name="regions">\n+                    <param name="regions_src" value="regions" />\n+                    <repeat name="region_specs">\n+                        <param name="chrom" value="1" />\n+                    </repeat>\n+                </conditional>\n             </section>\n             <output name="output_file">\n                 <assert_contents>\n@@ -312,12 +356,16 @@\n         <!-- Test min overlap option -->\n         <test>\n             <param name="input_file" ftype="vcf" value="annotate3.vcf" />\n-            <param name="anno_fmt" value="none" />\n-            <param name="remove" value="FORMAT" />\n-            <param name="output_type" value="v" />\n             <section name="sec_annofile">\n+                <conditional name="annofile">\n+                    <param name="anno_fmt" value="none" />\n+                </conditional>\n                 <param name="min_overlap" value="0.5"/>\n             </section>\n+            <section name="sec_annotate">\n+                <param name="remove" value="FORMAT" />\n+            </section>\n+            <param name="output_type" value="v" />\n             <output name="output_file">\n                 <assert_contents>\n                     <not_has_text text="GT:X:PL:Y:AA" />\n@@ -366,7 +414,7 @@\n \n @BCFTOOLS_MANPAGE@#@EXECUTABLE@\n \n-@BCFTOOLS_WIKI@\n+@BCFTOOLS_HOWTOS@\n ]]>\n     </help>\n     <expand macro="citations" />\n'
b
diff -r 2c372041ed8c -r 06eaadeffb7d macros.xml
--- a/macros.xml Sun Aug 18 09:59:56 2024 +0000
+++ b/macros.xml Tue Dec 02 08:19:20 2025 +0000
[
b'@@ -1,7 +1,7 @@\n <macros>\n-  <token name="@TOOL_VERSION@">1.15.1</token>\n-  <token name="@VERSION_SUFFIX@">4</token>\n-  <token name="@PROFILE@">20.01</token>\n+  <token name="@TOOL_VERSION@">1.22</token>\n+  <token name="@VERSION_SUFFIX@">0</token>\n+  <token name="@PROFILE@">24.1</token>\n   <xml name="bio_tools">\n       <xrefs>\n           <xref type="bio.tools">bcftools</xref>\n@@ -10,15 +10,15 @@\n   <xml name="requirements">\n     <requirements>\n       <requirement type="package" version="@TOOL_VERSION@">bcftools</requirement>\n-      <requirement type="package" version="1.15.1">htslib</requirement>\n+      <requirement type="package" version="1.22.1">htslib</requirement>\n       <yield />\n     </requirements>\n   </xml>\n   <xml name="samtools_requirement">\n-      <requirement type="package" version="1.15.1">samtools</requirement>\n+      <requirement type="package" version="1.22.1">samtools</requirement>\n   </xml>\n   <xml name="matplotlib_requirement">\n-      <requirement type="package" version="3.5.3">matplotlib</requirement>\n+      <requirement type="package" version="3.10.7">matplotlib</requirement>\n   </xml>\n   <xml name="version_command">\n     <version_command>bcftools 2&gt;&amp;1 | grep \'Version:\'</version_command>\n@@ -30,16 +30,11 @@\n       <yield />\n     </citations>\n   </xml>\n-  <token name="@BCFTOOLS_WIKI@">https://github.com/samtools/bcftools/wiki</token>\n-  <token name="@BCFTOOLS_MANPAGE@">http://samtools.github.io/bcftools/bcftools.html</token>\n+  <token name="@BCFTOOLS_HOWTOS@">https://samtools.github.io/bcftools/howtos/index.html</token>\n+  <token name="@BCFTOOLS_MANPAGE@">https://www.htslib.org/doc/bcftools.html</token>\n   <token name="@THREADS@">\n   --threads \\${GALAXY_SLOTS:-4}\n   </token>\n-  <token name="@PREPARE_ENV@">\n-<![CDATA[\n-export BCFTOOLS_PLUGINS=`which bcftools | sed \'s,bin/bcftools,libexec/bcftools,\'`;\n-]]>\n-  </token>\n   <xml name="macro_input">\n     <!-- \n     REQUIRES https://github.com/galaxyproject/galaxy/pull/14605/files\n@@ -294,8 +289,8 @@\n     help="inverts the query/filtering applied by the targets" />\n   </xml>\n \n-  <xml name="macro_restriction_spec" token_type="region" token_label_type="Region">\n-    <repeat name="@TYPE@s" title="@LABEL_TYPE@ Filter" default="1" min="1">\n+  <xml name="macro_restriction_spec" tokens="type,label_type">\n+    <repeat name="@TYPE@_specs" title="@LABEL_TYPE@ Filter" default="1" min="1">\n         <param name="chrom" type="text" label="@LABEL_TYPE@ chromosome">\n             <validator type="expression" message="A chromosome identifier is required when specifying a @LABEL_TYPE@ filter">value.strip()</validator>\n         </param>\n@@ -305,36 +300,85 @@\n         <param name="stop" type="text" label="@LABEL_TYPE@ end position">\n             <validator type="expression" message="an integer number is required">not value or value.isdigit()</validator>\n         </param>\n-        <yield />\n     </repeat>\n   </xml>\n \n-  <xml name="macro_restrictions_file" token_type="region" token_label_type="Region">\n+  <xml name="macro_restrictions_file" tokens="type,label_type">\n     <param name="@TYPE@s_file" type="data" format="tabular" label="@LABEL_TYPE@s File" help="restrict to @LABEL_TYPE@s listed in a file" />\n   </xml>\n \n-  <xml name="macro_restrict" token_type="region" token_label_type="Region" >\n+  <xml name="__macro_restrict__" tokens="type,label_select,label_type,pos_is_default,rec_is_default">\n     <conditional name="@TYPE@s">\n-        <param name="@TYPE@s_src" type="select" label="@LABEL_TYPE@s">\n-            <option value="__none__">Do not restrict to @LABEL_TYPE@s</option>\n-            <option value="@TYPE@s">Specify one or more @LABEL_TYPE@(s) directly</option>\n-            <option value="@TYPE@s_file">Operate on @LABEL_TYPE@s specified in a history dataset</option>\n+      <param name="@TYPE@s_src" type="select" label="@LABEL_SELECT@">\n+        <option value="__none__">Do not restrict to @LABEL_TYPE@s</option>\n+        <option value="@TYPE@s">Specify one or more @LABEL_TYPE@'..b'intervals = $section.targets.target_specs\n+    @PARSE_INTERVALS@\n+    --targets \'${section.targets.invert_targets_file}$intervals_spec\'\n+  #elif $section.targets.targets_src == \'targets_file\':\n+    #if $targets_path:\n+      --targets-file \'${section.targets.invert_targets_file}${targets_path}\'\n+    #else:\n+      --targets-file \'${section.targets.invert_targets_file}${section.targets.targets_file}\'\n+    #end if\n+  #end if\n+  #if \'targets_overlap\' in $section.targets:\n+    --targets-overlap $section.targets.targets_overlap\n+  #end if\n #end if\n ]]>\n   </token>\n@@ -417,7 +462,7 @@\n <![CDATA[\n #set $regions_path = None\n #if \'regions\' in $section\n-  #if $section.regions.regions_src == \'regions_file\' and $section.regions.regions_file:\n+  #if $section.regions.regions_src == \'regions_file\':\n     #if $section.regions.regions_file.ext.startswith(\'bed\'):\n       #set $regions_path = \'regions_file.bed\'\n       ln -s \'$section.regions.regions_file\' $regions_path &&\n@@ -461,11 +506,31 @@\n       </param>\n       <param name="invert_samples" type="boolean" truevalue="^" falsevalue="" checked="false" label="Invert Samples"\n              help="Inverts the query/filtering applied by Samples (adds &quot;^&quot; prefix to exclude)" />\n-      <param argument="--samples_file" type="data" format="tabular" optional="true" label="Samples file"\n-             help="File of samples to include" />\n+      <param argument="--samples_file" type="data" format="tabular" optional="true" label="Samples file" help="File of samples to include" />\n       <param name="invert_samples_file" type="boolean" truevalue="^" falsevalue="" checked="false" label="Invert Samples file"\n              help="inverts the query/filtering applied by Samples file" />\n   </xml>\n+\n+  <xml name="macro_samples_enhanced" token_all_samples="" token_file_help="File listing samples to include one per line.">\n+      <conditional name="specify_samples">\n+          <param name="how" type="select" label="How do you want to select samples?">\n+              <option value="-s">Specify samples manually</option>\n+              <option value="-S">Provide sample file</option>\n+              <option value="@ALL_SAMPLES@" selected="true">No selection; just use all samples found in input</option>\n+          </param>\n+          <when value="-s">\n+              <param argument="--samples" name="samples_spec" type="text" optional="false" label="Sample(s)" help="Specify a single sample by name or a comma-separated list of sample names.">\n+                <validator type="expression" message="Please specify a single sample by name or a comma-separated list of sample names">value.strip() and value[0] not in "^," and ",," not in value</validator>\n+              </param>\n+              <param name="invert_samples" type="boolean" truevalue="^" falsevalue="" label="Exclude these samples instead of including them?" help="Equivalent to prefixing the list of samples with &quot;^&quot; on the command line."/>\n+          </when>\n+          <when value="-S">\n+              <param argument="--samples_file" type="data" format="tabular" optional="@IS_OPTIONAL@" label="Samples file" help="@FILE_HELP@" />\n+              <param name="invert_samples" type="boolean" truevalue="^" falsevalue="" label="Exclude the samples listed in the file instead of including them?" help="Equivalent to prefixing the file with &quot;^&quot; on the command line."/>\n+          </when>\n+          <when value="@ALL_SAMPLES@" />\n+      </conditional>\n+  </xml>\n   <token name="@SAMPLES@">\n #set $samples_defined = False\n #if str($section.samples) != \'\':\n@@ -478,8 +543,8 @@\n #end if\n   </token>\n \n-  <xml name="macro_sample">\n-      <param name="sample" type="text" optional="true" label="Sample" help="Apply variants of the given sample" />\n+  <xml name="macro_sample" token_help="Apply variants of the given sample">\n+      <param name="sample" type="text" optional="true" label="Sample" help="@HELP@" />\n   </xml>\n   <token name="@SAMPLE@">\n #if $section.sample:\n'