Repository 'metawrapmg_binning'
hg clone https://toolshed.g2.bx.psu.edu/repos/galaxy-australia/metawrapmg_binning

Changeset 2:2a8bc1d26d06 (2024-04-11)
Previous changeset 1:e3a64a1d2a6e (2023-01-30)
Commit message:
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/metawrapmg commit 26fe7d23c5c3981c9b737109e5db799cc5d23932
modified:
macros.xml
metawrapmg_binning.xml
b
diff -r e3a64a1d2a6e -r 2a8bc1d26d06 macros.xml
--- a/macros.xml Mon Jan 30 22:30:51 2023 +0000
+++ b/macros.xml Thu Apr 11 21:56:14 2024 +0000
b
@@ -1,6 +1,6 @@
 <macros>
     <token name="@TOOL_VERSION@">1.3.0</token>
-    <token name="@VERSION_SUFFIX@">0</token>
+    <token name="@VERSION_SUFFIX@">1</token>
     <token name="@PROFILE@">22.05</token>
     <xml name="requirements">
         <requirements>
b
diff -r e3a64a1d2a6e -r 2a8bc1d26d06 metawrapmg_binning.xml
--- a/metawrapmg_binning.xml Mon Jan 30 22:30:51 2023 +0000
+++ b/metawrapmg_binning.xml Thu Apr 11 21:56:14 2024 +0000
[
b'@@ -6,100 +6,97 @@\n     <expand macro="xrefs"/>\n     <expand macro="requirements"/>\n     <command detect_errors="exit_code"><![CDATA[\n-            ## set memory usage\n-            if [ -n "\\$GALAXY_MEMORY_MB" ] ; then\n-                GALAXY_MEMORY_GB=\\$((GALAXY_MEMORY_MB / 1024)) ;\n-            fi ;\n+        ## set memory usage\n+        if [ -n "\\${GALAXY_MEMORY_MB}" ] ; then\n+            export GALAXY_MEMORY_GB="\\$((GALAXY_MEMORY_MB / 1024))" ;\n+        fi ;\n \n-            ##################\n-            ## SET UP FILES ##\n-            ##################\n-\n-            ## should always be FASTA\n-            #set mg_fn = \'metagenome.\' + str($metagenome.ext)\n-            ln -s \'$metagenome\' $mg_fn\n-            &&\n+        ##################\n+        ## SET UP FILES ##\n+        ##################\n \n-            ## Only FASTQ. Separate files for each sample. Metawrap checks for\n-            ## files named _1.fastq and _2.fastq.\n-            #set input1_fn = \'reads_1.fastq\'\n-            ln -s \'$input_1\' $input1_fn\n-            &&\n+        ## only plain FASTA and FASTQ\n+        ln -s \'$metagenome\' metagenome.fasta\n+        &&\n+        ## Metawrap checks for files named _1.fastq and _2.fastq.\n+        ln -s \'$input_1\' reads_1.fastq\n+        &&\n+        ln -s \'$input_2\' reads_2.fastq\n+        &&\n \n-            #set input2_fn = \'reads_2.fastq\'\n-            ln -s \'$input_2\' $input2_fn\n-            &&\n-\n-            #####################\n-            ## INITIAL BINNING ##\n-            #####################\n+        #####################\n+        ## INITIAL BINNING ##\n+        #####################\n \n-            metawrap binning \n-            --metabat2 --maxbin2 --concoct \n-            -a \'$mg_fn\'\n-            -m \\${GALAXY_MEMORY_GB:-16}\n-            -o INITIAL_BINNING\n-            -t \\${GALAXY_SLOTS:-4}\n-            \'$input1_fn\'\n-            \'$input2_fn\'\n-            &&\n+        metawrap binning \n+        --metabat2 --maxbin2 --concoct \n+        -a metagenome.fasta\n+        -m "\\${GALAXY_MEMORY_GB:-16}"\n+        -o INITIAL_BINNING\n+        -t "\\${GALAXY_SLOTS:-4}"\n+        reads_1.fastq\n+        reads_2.fastq\n+        &&\n \n-            ## Check which binning programs produced bins            \n-            bin_dirs=(INITIAL_BINNING/concoct_bins INITIAL_BINNING/maxbin2_bins INITIAL_BINNING/metabat2_bins) &&\n-            switches=(\'-A\' \'-B\' \'-C\') &&\n+        ## Check which binning programs produced bins            \n+        bin_dirs=(INITIAL_BINNING/concoct_bins INITIAL_BINNING/maxbin2_bins INITIAL_BINNING/metabat2_bins) &&\n+        switches=(\'-A\' \'-B\' \'-C\') &&\n \n-            i=0 &&\n-            bin_string="" &&\n+        i=0 &&\n+        bin_string="" &&\n \n-            for dir in "\\${bin_dirs[@]}" ; do\n-                if find "\\${dir}" -mindepth 1 -maxdepth 1 | read; then\n-                    bin_string="\\${bin_string} \\${switches[\\$i]} \\${dir}" ;\n-                    i+=1 ;\n-                fi\n-            done &&\n+        for dir in "\\${bin_dirs[@]}" ; do\n+            if [ "\\$(find "\\$dir" -mindepth 1 -maxdepth 1 -exec echo found \\;)" ]; then\n+                bin_string+=" \\${switches[\\$i]} \\$dir" ;\n+                ((i++)) ;\n+            fi\n+        done &&\n \n-            ####################\n-            ## BIN REFINEMENT ##\n-            ####################\n+        ####################\n+        ## BIN REFINEMENT ##\n+        ####################\n \n-            ## The checkm database is included in the conda package.\n-            ## Requires metawrap-mg_1.3.0--hdfd78af_1 or later. See\n-            ## https://github.com/bioconda/bioconda-recipes/pull/38299.\n+        ## The checkm database is in the conda package, see\n+        ## https://github.com/bioconda/bioconda-recipes/pull/38299.\n \n-            metawrap bin_refinement\n-            -t \\${GALAXY_SLOTS:-4}\n-            -m \\${GALAXY_MEMORY_GB:-16}\n-            -c $binning.c\n-            -x $binning.x\n-            -o BIN_REFINEMENT\n-            ## Only run bin_refinement on bins wit'..b' 2" help="Original reads that were used for the assembly: read 2."/>\n         <section name="binning" title="Binning parameters" expanded="false">\n-            <param argument=\'-c\' type="integer" value="70" min="50" max="100" label="Percent completion" help="Minimum % completion of bins" />\n-            <param argument=\'-x\' type="integer" value="10" min="0" max="100" label="Percent contamination" help="Maximum % contamination of bins that is acceptable" />\n+            <param argument="-c" type="integer" value="70" min="50" max="100" label="Percent completion" help="Minimum % completion of bins"/>\n+            <param argument="-x" type="integer" value="10" min="0" max="100" label="Percent contamination" help="Maximum % contamination of bins that is acceptable"/>\n         </section>\n+        <!-- the pplacer component requires 40 GB per thread. Skip pplacer for\n+         testing by setting this to "quick" -->\n+        <param name="hidden_quick" type="hidden" value=""/>\n     </inputs>\n     <outputs>\n         <!-- contigs binned into fasta files -->\n         <collection name="metawrap_bins" type="list" label="MetaWRAP on ${on_string}: bins">\n-            <discover_datasets pattern="metawrap_\\d+_\\d+_bins/(?P&lt;designation&gt;.+)\\.fa" format="fasta" directory="BIN_REFINEMENT" recurse="true" match_relative_path="true" visible="false" />\n+            <discover_datasets pattern="metawrap_\\d+_\\d+_bins/(?P&lt;designation&gt;.+)\\.fa" format="fasta" directory="BIN_REFINEMENT" recurse="true" match_relative_path="true"/>\n         </collection>\n         <!-- summary figures -->\n         <collection name="metawrap_figures" type="list" label="MetaWRAP on ${on_string}: summary figures">\n-            <discover_datasets pattern="__designation_and_ext__" directory="BIN_REFINEMENT/figures" visible="false" />\n+            <discover_datasets pattern="__designation_and_ext__" directory="BIN_REFINEMENT/figures"/>\n         </collection>\n         <!-- statistics on binning -->\n         <collection name="metawrap_stats" type="list" label="MetaWRAP on ${on_string}: stat files">\n-            <discover_datasets pattern="(?P&lt;designation&gt;.+)\\.stats" format="tabular" directory="BIN_REFINEMENT" visible="false" />\n+            <discover_datasets pattern="(?P&lt;designation&gt;.+)\\.stats" format="tabular" directory="BIN_REFINEMENT"/>\n         </collection>\n         <!-- which contig went into which bin -->\n         <collection name="metawrap_contigs" type="list" label="MetaWRAP on ${on_string}: contig assignments">\n-            <discover_datasets pattern="(?P&lt;designation&gt;.+)\\.contigs" format="tabular" directory="BIN_REFINEMENT" visible="false" />\n+            <discover_datasets pattern="(?P&lt;designation&gt;.+)\\.contigs" format="tabular" directory="BIN_REFINEMENT"/>\n         </collection>\n     </outputs>\n     <tests>\n@@ -110,10 +107,14 @@\n             <param name="input_2" value="mapped_reads.r2.fastq.gz"/>\n             <param name="c" value="60"/>\n             <param name="x" value="15"/>\n-            <!-- this is the main output, but it\'s too large to test -->\n-            <!-- <output_collection name="metawrap_bins" type="list">\n-                <element name="bin.1" file="test02.fa" ftype="fasta"/>\n-            </output_collection> -->\n+            <param name="hidden_quick" value="--quick"/>\n+            <output_collection name="metawrap_bins" type="list">\n+                <element name="bin.1" ftype="fasta">\n+                    <assert_contents>\n+                        <has_text text="NODE_2_length_"/>\n+                    </assert_contents>\n+                </element>\n+            </output_collection>\n             <output_collection name="metawrap_stats" type="list">\n                 <element name="metawrap_60_15_bins" file="test02.stats" ftype="tabular"/>\n             </output_collection>\n@@ -122,7 +123,7 @@\n             </output_collection>\n         </test>\n     </tests>\n-        <help><![CDATA[\n+    <help><![CDATA[\n MetaWRAP\n --------\n \n'