2021-03-24 16:14:52 +00:00
|
|
|
process YARA_INDEX {
|
|
|
|
tag "$fasta"
|
|
|
|
label 'process_medium'
|
|
|
|
|
|
|
|
conda (params.enable_conda ? "bioconda::yara=1.0.2" : null)
|
2021-11-26 07:58:40 +00:00
|
|
|
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
|
|
|
|
'https://depot.galaxyproject.org/singularity/yara:1.0.2--2' :
|
|
|
|
'quay.io/biocontainers/yara:1.0.2--2' }"
|
2021-03-24 16:14:52 +00:00
|
|
|
|
|
|
|
input:
|
|
|
|
path fasta
|
|
|
|
|
|
|
|
output:
|
2021-09-28 13:37:47 +00:00
|
|
|
path "yara" , emit: index
|
2021-10-01 13:04:56 +00:00
|
|
|
path "versions.yml", emit: versions
|
2021-03-24 16:14:52 +00:00
|
|
|
|
|
|
|
script:
|
2021-11-26 07:58:40 +00:00
|
|
|
def args = task.ext.args ?: ''
|
2021-03-24 16:14:52 +00:00
|
|
|
|
|
|
|
"""
|
|
|
|
mkdir yara
|
2021-09-28 13:37:47 +00:00
|
|
|
|
|
|
|
yara_indexer \\
|
|
|
|
$fasta \\
|
|
|
|
-o "yara"
|
|
|
|
|
2021-03-24 16:14:52 +00:00
|
|
|
mv *.{lf,rid,sa,txt}.* yara
|
|
|
|
cp $fasta yara/yara.fasta
|
|
|
|
|
2021-09-27 08:41:24 +00:00
|
|
|
cat <<-END_VERSIONS > versions.yml
|
2021-11-26 07:58:40 +00:00
|
|
|
"${task.process}":
|
|
|
|
yara: \$(echo \$(yara_indexer --version 2>&1) | sed 's/^.*yara_indexer version: //; s/ .*\$//')
|
2021-09-27 08:41:24 +00:00
|
|
|
END_VERSIONS
|
2021-03-24 16:14:52 +00:00
|
|
|
"""
|
|
|
|
}
|