# HG changeset patch
# User iuc
# Date 1755889465 0
# Node ID 47189346d00d42e98ee2b368a92ebee59054a257
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/main/tools/metasbt commit 5509a3fab8eb49e931a5fde335dd7030e16737f5
diff -r 000000000000 -r 47189346d00d index.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/index.xml Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,339 @@
+
+
+ genomes with Sequence Bloom Trees or update an existing database
+
+
+ macros.xml
+
+
+
+
+ "\${target_fna}" &&
+ #else
+ ln -s '${genome}' "\${target_fna}" &&
+ #end if
+
+ echo -e "\${target_fna}" >> "./genomes.txt" &&
+#end for
+
+#if $advanced.index_update_conditional.index_update_option == "false":
+ while IFS=$'\t' read -r genome_name genome_taxonomy; do
+ genome_name="\$(echo '\${genome_name}' | sed 's/[^[:alnum:]_.-]/_/g')" &&
+ genome_taxonomy="\$(echo '\${genome_taxonomy}' | sed 's/[^[:alnum:]_.-|]/_/g')" &&
+
+ if [ -f "${input_dir}/\${genome_name}.fna" ]; then
+ echo -e "${input_dir}/\${genome_name}.fna\t\${genome_taxonomy}" >> "${input_dir}/genomes.tsv";
+ fi
+ done < '${taxonomies}' &&
+
+ metasbt index --workdir "."
+ --database "Database"
+ --references "${input_dir}/genomes.tsv"
+ --nproc "\${GALAXY_SLOTS:-4}"
+ --pack
+
+ #if $advanced.index_update_conditional.bfs_selection.bfs_auto == "false":
+ --filter-size '${advanced.index_update_conditional.bfs_selection.bfs_size}'
+ #else:
+ --increase-filter-size '${advanced.index_update_conditional.bfs_selection.bfs_size_increase}'
+ --min-kmer-occurrences '${advanced.index_update_conditional.bfs_selection.min_kmer_occurrences}'
+ #end if
+
+ #if $advanced.index_update_conditional.kmers_selection.kmers_auto == "false":
+ --kmer-size '${advanced.index_update_conditional.kmers_selection.kmer_len}'
+ #else:
+ --limit-kmer-size '${advanced.index_update_conditional.kmers_selection.max_kmer_len}'
+ #end if
+
+ #if $advanced.dereplication_selection.dereplication == "true":
+ --dereplicate '${advanced.dereplication_update_conditional.distance_threshold}'
+ #end if
+
+ #if $advanced.quality_control_selection.quality_control == "true":
+ --completeness '${advanced.quality_control_selection.completeness}'
+ --contamination '${advanced.quality_control_selection.contamination}'
+ #end if
+
+ &&
+#else:
+ #if $advanced.index_update_conditional.database_selection.source == "cvmfs":
+ ln -s '${advanced.index_update_conditional.database_selection.db_tarball.fields.path}' "./MetaSBT-Database.tar.gz" &&
+ #else:
+ ln -s '${advanced.index_update_conditional.database_selection.db_tarball}' "./MetaSBT-Database.tar.gz" &&
+ #end if
+
+ metasbt unpack --workdir "."
+ --database "Database"
+ --tarball "./MetaSBT-Database.tar.gz" &&
+
+ rm "./MetaSBT-Database.tar.gz" &&
+
+ metasbt update --workdir "."
+ --database "Database"
+ --genomes "./genomes.txt"
+ --nproc "\${GALAXY_SLOTS:-4}"
+ --pack
+
+ #if $advanced.dereplication_selection.dereplication == "true":
+ --dereplicate '${advanced.dereplication_selection.distance_threshold}'
+ #end if
+
+ #if $advanced.quality_control_selection.quality_control == "true":
+ --completeness '${advanced.quality_control_selection.completeness}'
+ --contamination '${advanced.quality_control_selection.contamination}'
+ #end if
+
+ &&
+#end if
+
+tail -n +3 "./Database/clusters.tsv" > clusters.tsv &&
+tail -n +3 "./Database/genomes.tsv" > genomes.tsv &&
+
+mv ./MetaSBT-Database*.tar.gz MetaSBT-Database.tar.gz
+ ]]>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r 000000000000 -r 47189346d00d macros.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/macros.xml Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,68 @@
+
+ 0.1.5
+ 1
+ 24.00
+
+
+
+
+
+
+
+
+
+
+
+ sed
+ metasbt
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+@misc{metasbtrepo,
+ author={Fabio Cumbo, Daniel Blankenberg},
+ title={{MetaSBT: A scalable framework for automatically indexing microbial genomes and accurately characterizing metagenome-assembled genomes with Sequence Bloom Trees}},
+ publisher={Github},
+ url={https://github.com/cumbof/MetaSBT}
+}
+
+
+
+
\ No newline at end of file
diff -r 000000000000 -r 47189346d00d test-data/MetaSBT-Test-20250620.1.tar.gz
Binary file test-data/MetaSBT-Test-20250620.1.tar.gz has changed
diff -r 000000000000 -r 47189346d00d test-data/genome_1.fna.gz
Binary file test-data/genome_1.fna.gz has changed
diff -r 000000000000 -r 47189346d00d test-data/genome_1.tsv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/genome_1.tsv Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,11 @@
+level closest ani
+kingdom k__Viruses 0.01795
+phylum k__Viruses|p__Nucleocytoviricota 0.01743
+class k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes 0.01743
+order k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales 0.01743
+family k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae 0.01743
+genus k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus 0.01743
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus 0.00154
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Skunkpox_virus 0.02526
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Raccoonpox_virus 0.02548
+genome k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus|t__GCA_028389905.1_ASM2838990v1_genomic 0.00154
diff -r 000000000000 -r 47189346d00d test-data/genome_2.fna.gz
Binary file test-data/genome_2.fna.gz has changed
diff -r 000000000000 -r 47189346d00d test-data/genome_2.tsv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/genome_2.tsv Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,11 @@
+level closest ani
+kingdom k__Viruses 0.01846
+phylum k__Viruses|p__Nucleocytoviricota 0.01743
+class k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes 0.01743
+order k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales 0.01743
+family k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae 0.01743
+genus k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus 0.01743
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus 0.00119
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Skunkpox_virus 0.02545
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Raccoonpox_virus 0.02566
+genome k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus|t__GCA_028389905.1_ASM2838990v1_genomic 0.00119
diff -r 000000000000 -r 47189346d00d test-data/genome_3.fna.gz
Binary file test-data/genome_3.fna.gz has changed
diff -r 000000000000 -r 47189346d00d test-data/genome_3.tsv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/genome_3.tsv Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,10 @@
+level closest ani
+kingdom k__Viruses 0.01765
+phylum k__Viruses|p__Nucleocytoviricota 0.01699
+class k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes 0.01699
+order k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales 0.01699
+family k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae 0.01699
+genus k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus 0.01699
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus 0.00034
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Skunkpox_virus 0.02521
+genome k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus|t__GCA_028389905.1_ASM2838990v1_genomic 0.00034
diff -r 000000000000 -r 47189346d00d test-data/genome_4.fna.gz
Binary file test-data/genome_4.fna.gz has changed
diff -r 000000000000 -r 47189346d00d test-data/genome_4.tsv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/genome_4.tsv Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,10 @@
+level closest ani
+kingdom k__Viruses 0.01829
+phylum k__Viruses|p__Nucleocytoviricota 0.01741
+class k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes 0.01741
+order k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales 0.01741
+family k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae 0.01741
+genus k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus 0.01741
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus 0.00101
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Skunkpox_virus 0.02553
+genome k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus|t__GCA_028389905.1_ASM2838990v1_genomic 0.00101
diff -r 000000000000 -r 47189346d00d test-data/genome_5.fna.gz
Binary file test-data/genome_5.fna.gz has changed
diff -r 000000000000 -r 47189346d00d test-data/genome_5.tsv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/genome_5.tsv Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,11 @@
+level closest ani
+kingdom k__Viruses 0.39054
+phylum k__Viruses|p__Nucleocytoviricota 0.38041
+class k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes 0.38041
+order k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales 0.38041
+family k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae 0.38041
+genus k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus 0.38041
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Skunkpox_virus 0.38091
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus 0.38065
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Raccoonpox_virus 0.37966
+genome k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus|t__GCA_028389905.1_ASM2838990v1_genomic 0.38065
diff -r 000000000000 -r 47189346d00d test-data/genome_6.fna.gz
Binary file test-data/genome_6.fna.gz has changed
diff -r 000000000000 -r 47189346d00d test-data/genome_6.tsv
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/genome_6.tsv Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,11 @@
+level closest ani
+kingdom k__Viruses 0.44364
+phylum k__Viruses|p__Nucleocytoviricota 0.43076
+class k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes 0.43076
+order k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales 0.43076
+family k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae 0.43076
+genus k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus 0.43076
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Skunkpox_virus 0.42999
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Monkeypox_virus 0.43146
+species k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Raccoonpox_virus 0.43083
+genome k__Viruses|p__Nucleocytoviricota|c__Pokkesviricetes|o__Chitovirales|f__Poxviridae|g__Orthopoxvirus|s__Skunkpox_virus|t__GCA_001745695.1_ViralProj344115_genomic 0.43072
diff -r 000000000000 -r 47189346d00d test-data/metasbt_databases.loc
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/metasbt_databases.loc Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,7 @@
+# Tab separated with four columns:
+# - value (Galaxy records this in the Galaxy DB)
+# - version (MetaSBT DB version)
+# - name (Galaxy shows this in the UI)
+# - path (file path to the MetaSBT database)
+#
+test_db test Test Database ${__HERE__}/MetaSBT-Test-20250620.1.tar.gz
\ No newline at end of file
diff -r 000000000000 -r 47189346d00d tool-data/metasbt_databases.loc
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tool-data/metasbt_databases.loc Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,12 @@
+# Expect four columns, tab separated, as follows:
+# - value (Galaxy records this in the Galaxy DB)
+# - version (MetaSBT DB version)
+# - name (Galaxy shows this in the UI)
+# - path with or without trailing slash (folder name containing the MetaSBT DB)
+#
+# e.g.
+# viruses_2025011520250115"Viruses (References)"/path/to/MetaSBT-Viruses-20250115.tar.gz
+# value version name path
+viruses_20250115 20250115 Viruses (References) /cvmfs/data.galaxyproject.org/byhand/MetaSBT/MetaSBT-Viruses-20250115.tar.gz
+viruses_20250118 20250118 Viruses (References+MAGs) /cvmfs/data.galaxyproject.org/byhand/MetaSBT/MetaSBT-Viruses-20250118.tar.gz
+viruses_20250320 20250320 Viruses (References+MAGs+MGV) /cvmfs/data.galaxyproject.org/byhand/MetaSBT/MetaSBT-Viruses-20250320.tar.gz
diff -r 000000000000 -r 47189346d00d tool_data_table_conf.xml.sample
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tool_data_table_conf.xml.sample Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,8 @@
+
+
+
+
+ value, version, name, path
+
+
+
\ No newline at end of file
diff -r 000000000000 -r 47189346d00d tool_data_table_conf.xml.test
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tool_data_table_conf.xml.test Fri Aug 22 19:04:25 2025 +0000
@@ -0,0 +1,8 @@
+
+
+
+
+ value, version, name, path
+
+
+
\ No newline at end of file