mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-23 03:28:17 +00:00
32ad1746d1
* Add vsearch sintax process * Add tests for vsearch sintax * Add vsearch sintax process * Add tests for vsearch sintax * Update format with prettier * Remove trailing whitespace Co-authored-by: nvnieuwk <101190534+nvnieuwk@users.noreply.github.com>
38 lines
1.1 KiB
Text
38 lines
1.1 KiB
Text
process VSEARCH_SINTAX {
|
|
tag "${meta.id}"
|
|
label 'process_low'
|
|
|
|
conda (params.enable_conda ? "bioconda::vsearch=2.21.1" : null)
|
|
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
|
|
'https://depot.galaxyproject.org/singularity/vsearch:2.21.1--h95f258a_0':
|
|
'quay.io/biocontainers/vsearch:2.21.1--h95f258a_0' }"
|
|
|
|
input:
|
|
tuple val(meta), path(queryfasta)
|
|
path db
|
|
|
|
output:
|
|
tuple val(meta), path('*.tsv') , optional: true, emit: tsv
|
|
path "versions.yml" , emit: versions
|
|
|
|
when:
|
|
task.ext.when == null || task.ext.when
|
|
|
|
script:
|
|
def args = task.ext.args ?: ''
|
|
def prefix = task.ext.prefix ?: "${meta.id}"
|
|
|
|
"""
|
|
vsearch \\
|
|
--sintax $queryfasta \\
|
|
--db $db \\
|
|
--threads $task.cpus \\
|
|
$args \\
|
|
--tabbedout ${prefix}.tsv
|
|
|
|
cat <<-END_VERSIONS > versions.yml
|
|
"${task.process}":
|
|
vsearch: \$(vsearch --version 2>&1 | head -n 1 | sed 's/vsearch //g' | sed 's/,.*//g' | sed 's/^v//' | sed 's/_.*//')
|
|
END_VERSIONS
|
|
"""
|
|
}
|