nf-core_modules/modules/pasty/main.nf
Robert A. Petit III 3ef618fed2
add module for pasty (#2003)
* add module for pasty

* run prettier

* line up those commas

* Update main.nf
2022-09-07 09:29:28 -06:00

36 lines
1.1 KiB
Text

process PASTY {
tag "$meta.id"
label 'process_single'
conda (params.enable_conda ? "bioconda::pasty=1.0.0" : null)
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/pasty:1.0.0--hdfd78af_0':
'quay.io/biocontainers/pasty:1.0.0--hdfd78af_0' }"
input:
tuple val(meta), path(fasta)
output:
tuple val(meta), path("${prefix}.tsv") , emit: tsv
tuple val(meta), path("${prefix}.blastn.tsv") , emit: blast
tuple val(meta), path("${prefix}.details.tsv"), emit: details
path "versions.yml" , emit: versions
when:
task.ext.when == null || task.ext.when
script:
def args = task.ext.args ?: ''
prefix = task.ext.prefix ?: "${meta.id}"
"""
pasty \\
$args \\
--prefix $prefix \\
--assembly $fasta
cat <<-END_VERSIONS > versions.yml
"${task.process}":
pasty: \$(echo \$(pasty --version 2>&1) | sed 's/^.*pasty, version //;' )
END_VERSIONS
"""
}