Mercurial > repos > iuc > snippy
changeset 16:cfbd9a5694ff draft default tip
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/snippy commit bc5bbb26c53bf2455043cf4b8f552571e6f74530
author | iuc |
---|---|
date | Mon, 20 Jan 2025 10:09:34 +0000 |
parents | b23add4731b4 |
children | |
files | macros.xml.orig snippy.xml test-data/contigs.fasta test-data/d_fna_ref_mincov_1_minqual_60.snps.gff test-data/d_fna_ref_mincov_1_minqual_60.snps.txt |
diffstat | 5 files changed, 51 insertions(+), 89 deletions(-) [+] |
line wrap: on
line diff
--- a/macros.xml.orig Wed Sep 01 08:39:51 2021 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,83 +0,0 @@ -<macros> - <xml name="requirements"> - <requirements> - <requirement type="package" version="@WRAPPER_VERSION@">snippy</requirement> - <requirement type="package" version="1.32">tar</requirement> - <yield /> - </requirements> - </xml> -<<<<<<< HEAD - - <token name="@WRAPPER_VERSION@">4.6.0</token> - <token name="@VERSION_SUFFIX@">0</token> -======= - <xml name="bio_tools"> - <xrefs> - <xref type='bio.tools'>snippy</xref> - </xrefs> - </xml> - <token name="@WRAPPER_VERSION@">4.5.0</token> - <token name="@VERSION_SUFFIX@">1</token> ->>>>>>> 3b8498343 (and the rest) - - <xml name="version_command"> - <version_command><![CDATA[snippy --version]]></version_command> - </xml> - - <token name="@REFERENCE_SOURCE_FILE@"> - <![CDATA[ - #if $reference_source.reference_source_selector == 'history' - #if $reference_source.ref_file.is_of_type("fasta") - ln -sf '$reference_source.ref_file' 'ref.fna' && - #elif $reference_source.ref_file.is_of_type("genbank") - ln -sf '$reference_source.ref_file' 'ref.gbk' && - #end if - #elif $reference_source.reference_source_selector == 'cached' - ln -sf '$reference_source.ref_file.fields.path' 'ref.fna' && - #end if]]> - </token> - - <token name="@REFERENCE_COMMAND@"> - <![CDATA[ - #if $reference_source.reference_source_selector == 'history' - #if $reference_source.ref_file.is_of_type("fasta") - --ref 'ref.fna' - #elif $reference_source.ref_file.is_of_type("genbank") - --ref 'ref.gbk' - #end if - #elif $reference_source.reference_source_selector == 'cached' - --ref 'ref.fna' - #end if - ]]> - </token> - - <xml name="reference_selector"> - <conditional name="reference_source"> - <param name="reference_source_selector" type="select" label="Will you select a reference genome from your history or use a built-in index?" help="Built-ins were indexed using default options. See `Indexes` section of help below. If you would like to perform self-mapping select `history` here, then choose your input file as reference."> - <option value="cached">Use a built-in genome index</option> - <option value="history">Use a genome from history and build index</option> - </param> - <when value="cached"> - <param name="ref_file" type="select" label="Using reference genome" help="Select genome from the list"> - <options from_data_table="all_fasta"> - <validator type="no_options" message="No reference genomes are available" /> - </options> - </param> - </when> - <when value="history"> - <param name="ref_file" type="data" format="fasta,fasta.gz,genbank" label="Use the following dataset as the reference sequence" help="You can upload a FASTA or FASTQ sequence to the history and use it as reference" /> - </when> - </conditional> - </xml> - - <xml name="citations"> - <citations> - <citation type="bibtex">@UNPUBLISHED{Seemann2013, - author = "Seemann T", - title = "snippy: fast bacterial variant calling from NGS reads", - year = "2015", - note = "https://github.com/tseemann/snippy", - url = "https://github.com/tseemann/snippy"}</citation> - </citations> - </xml> -</macros>
--- a/snippy.xml Wed Sep 01 08:39:51 2021 +0000 +++ b/snippy.xml Mon Jan 20 10:09:34 2025 +0000 @@ -2,7 +2,6 @@ <description> Snippy finds SNPs between a haploid reference genome and your NGS sequence reads. </description> - <expand macro="bio_tools"/> <macros> <import>macros.xml</import> </macros> @@ -22,6 +21,8 @@ #set $dir_name = re.sub('[^\w_]', '_', $fastq_input.fastq_input_single.element_identifier) #elif str( $fastq_input.fastq_input_selector ) == "paired_iv" #set $dir_name = re.sub('[^\w_]', '_', $fastq_input.fastq_input_interleaved.element_identifier) + #elif str( $fastq_input.fastq_input_selector ) == "contigs" + #set $dir_name = re.sub('[^\w_]', '_', $fastq_input.fasta_input.element_identifier) #end if snippy @@ -50,6 +51,8 @@ --se '$fastq_input.fastq_input_single' #elif str( $fastq_input.fastq_input_selector ) == "paired_iv" --peil '$fastq_input.fastq_input_interleaved' + #elif str( $fastq_input.fastq_input_selector ) == "contigs" + --ctgs '$fastq_input.fasta_input' #end if #if "outcon" in str($outputs) and $adv.rename_cons @@ -63,11 +66,12 @@ <inputs> <expand macro="reference_selector" /> <conditional name="fastq_input"> - <param name="fastq_input_selector" type="select" label="Single or Paired-end reads" help="Select between paired and single end data"> - <option value="paired">Paired</option> - <option value="single">Single</option> - <option value="paired_collection">Paired Collection</option> - <option value="paired_iv">Paired Interleaved</option> + <param name="fastq_input_selector" type="select" label="Input type" help="Select paired/single end raw read data or assembled contigs"> + <option value="paired">Paired end reads</option> + <option value="single">Single end reads</option> + <option value="paired_collection">Paired end reads in a collection</option> + <option value="paired_iv">Interleaved paired end reads</option> + <option value="contigs">Assembled Contigs</option> </param> <when value="paired"> <param name="fastq_input1" type="data" format="fastqsanger,fastqsanger.gz,fasta,fasta.gz" label="Select first set of reads" help="Specify dataset with forward reads"/> @@ -82,6 +86,10 @@ <when value="paired_iv"> <param name="fastq_input_interleaved" type="data" format="fastqsanger,fastqsanger.gz" label="Select fastq dataset" help="Specify dataset with interleaved reads"/> </when> + <when value="contigs"> + <param name="fasta_input" type="data" format="fasta" label="Select fasta dataset" help="Specify dataset with assembled contigs"/> + </when> + </conditional> <section name="adv" title="Advanced parameters" expanded="false"> @@ -219,6 +227,22 @@ <output name="snpsum" ftype="tabular" file="b_fna_ref_mincov_2_minqual_60.snps.txt" lines_diff="8" /> <output name="snpgff" ftype="gff3" file="b_2_fna_ref_mincov_2_minqual_60.snps.gff" lines_diff="2"/> </test> + + <test> <!-- test 5 - fasta ref one snp single --> + <conditional name="reference_source"> + <param name="reference_source_selector" value="history"/> + <param name="ref_file" value="reference.fasta" ftype="fasta"/> + </conditional> + <conditional name="fastq_input"> + <param name="fastq_input_selector" value="contigs" /> + <param name="fasta_input" value="contigs.fasta" ftype="fasta" /> + </conditional> + <param name="mincov" value="2" /> + <param name="minqual" value="60" /> + <param name="outputs" value="outgff,outsum" /> + <output name="snpsum" ftype="tabular" file="d_fna_ref_mincov_1_minqual_60.snps.txt" lines_diff="6" /> + <output name="snpgff" ftype="gff3" file="d_fna_ref_mincov_1_minqual_60.snps.gff" lines_diff="2"/> + </test> </tests>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/contigs.fasta Mon Jan 20 10:09:34 2025 +0000 @@ -0,0 +1,11 @@ +>reference +TCCACAAGCCATTGTGTGTAATTAACCACTAATTGTGTATAAGTTTAAACTAATTGAAAAGGTTATCCAC +AATAAAAAGGCGTTATTCAGGAGTTATCCACACTTTCTAGGAAAGGATTTCATTGCGCCAATGTGTTAAA +TTATTTACCGAATACGAAAAAAAGACAAATAAATGAGGTTGTGAAAAATGATATTTCAACGGCTTTTGAA +GACTAGAGATACAGAGTTTTATCGAGTTATACAAAACAGGAATATTGACGACGTATTTGGATACTTATTA +ATTCACGATAAACGGGAACCAGCAGAAATTGACGATTTTAAGGTATTTGCAAAAAGTAATATAAATAAAG +AAGCTTTTTCAGTGAATATCAAAAAAAATCATATTTACACGATGTTTTTCCACTTTACTGATTTAGAGGA +AGAACAGGAAATTCCAAAATTTACTAAAGTTATTCGTTTTATAGAAGGACTTTTATCTTTTCAGCCAGAA +ACAAGCCATTACGTTGATAACTATTTAATAAAGGAAAAACTAATTTTTGAATATCCTGCTGAATTTGAGA +AAATCGGGGAGTTTGCTAAATATTTAGTAAAGCTTTCGGGTCGTAAAATTACTATTCCAGACACAACGAG +AGAAAAATATATCTATTTAACGCAATAATTTTCGAAAAATGGTTTTTCTCTCTATAAAAATATGATATGA
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/d_fna_ref_mincov_1_minqual_60.snps.gff Mon Jan 20 10:09:34 2025 +0000 @@ -0,0 +1,3 @@ +##gff-version 3 +reference snippy:4.6.0 variation 141 141 . . 0 note=snp C=>T T:4 C:0 +reference snippy:4.6.0 variation 211 211 . . 0 note=snp A=>G G:5 A:0
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/d_fna_ref_mincov_1_minqual_60.snps.txt Mon Jan 20 10:09:34 2025 +0000 @@ -0,0 +1,7 @@ +DateTime 2025-01-15T12:20:46 +ReadFiles fake_reads.fq +Reference reference.fasta +ReferenceSize 700 +Software snippy 4.6.0 +Variant-SNP 2 +VariantTotal 2