mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-22 11:08:17 +00:00
rename file_type to output extension
This commit is contained in:
parent
1de1c2253e
commit
5bd456e5e8
1 changed files with 4 additions and 4 deletions
|
@ -21,8 +21,8 @@ process SAMTOOLS_CONVERT {
|
||||||
|
|
||||||
script:
|
script:
|
||||||
def args = task.ext.args ?: ''
|
def args = task.ext.args ?: ''
|
||||||
prefix = task.ext.prefix ?: "${meta.id}"
|
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||||
def file_type = input.getExtension() == "bam" ? "cram" : "bam"
|
def output_extension = input.getExtension() == "bam" ? "cram" : "bam"
|
||||||
|
|
||||||
"""
|
"""
|
||||||
samtools view \\
|
samtools view \\
|
||||||
|
@ -30,9 +30,9 @@ process SAMTOOLS_CONVERT {
|
||||||
--reference ${fasta} \\
|
--reference ${fasta} \\
|
||||||
$args \\
|
$args \\
|
||||||
$input \\
|
$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
|
cat <<-END_VERSIONS > versions.yml
|
||||||
"${task.process}":
|
"${task.process}":
|
||||||
|
|
Loading…
Reference in a new issue