From 5bd456e5e8cdc9cf8a34ce9bc5fc1f949714e0fe Mon Sep 17 00:00:00 2001 From: Rike Date: Mon, 9 May 2022 16:06:22 +0200 Subject: [PATCH] rename file_type to output extension --- modules/samtools/convert/main.nf | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/samtools/convert/main.nf b/modules/samtools/convert/main.nf index b20f2b93..4638d360 100644 --- a/modules/samtools/convert/main.nf +++ b/modules/samtools/convert/main.nf @@ -21,8 +21,8 @@ process SAMTOOLS_CONVERT { script: def args = task.ext.args ?: '' - prefix = task.ext.prefix ?: "${meta.id}" - def file_type = input.getExtension() == "bam" ? "cram" : "bam" + def prefix = task.ext.prefix ?: "${meta.id}" + def output_extension = input.getExtension() == "bam" ? "cram" : "bam" """ samtools view \\ @@ -30,9 +30,9 @@ process SAMTOOLS_CONVERT { --reference ${fasta} \\ $args \\ $input \\ - -o ${prefix}.${file_type} + -o ${prefix}.${output_extension} - samtools index -@${task.cpus} ${prefix}.${file_type} + samtools index -@${task.cpus} ${prefix}.${output_extension} cat <<-END_VERSIONS > versions.yml "${task.process}":