mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-11-14 13:43:09 +00:00
f9d25aad7f
* fix: remove left-over unnecessary code * Update main.nf * Update hmmer/hmmalign command to natively accept gzipped input * Making @drpatelh happy Co-authored-by: Moritz E. Beber <midnighter@posteo.net> Co-authored-by: Moritz E. Beber <midnighter@posteo.net>
35 lines
993 B
Text
35 lines
993 B
Text
process HMMER_HMMALIGN {
|
|
tag "$meta.id"
|
|
label 'process_medium'
|
|
|
|
conda (params.enable_conda ? "bioconda::hmmer=3.3.2" : null)
|
|
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
|
|
'https://depot.galaxyproject.org/singularity/hmmer:3.3.2--h1b792b2_1' :
|
|
'quay.io/biocontainers/hmmer:3.3.2--h1b792b2_1' }"
|
|
|
|
input:
|
|
tuple val(meta), path(fasta)
|
|
path hmm
|
|
|
|
output:
|
|
tuple val(meta), path("*.sthlm.gz"), emit: sthlm
|
|
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}"
|
|
"""
|
|
hmmalign \\
|
|
$args \\
|
|
$hmm \\
|
|
$fasta | gzip -c > ${meta.id}.sthlm.gz
|
|
|
|
cat <<-END_VERSIONS > versions.yml
|
|
"${task.process}":
|
|
hmmer: \$(hmmalign -h | grep -o '^# HMMER [0-9.]*' | sed 's/^# HMMER *//')
|
|
END_VERSIONS
|
|
"""
|
|
}
|