Skip to content
Snippets Groups Projects
Verified Commit cb215113 authored by Laurent Modolo's avatar Laurent Modolo
Browse files

cutadapt: update output name and capture

parent 5af36606
No related branches found
No related tags found
No related merge requests found
...@@ -17,7 +17,7 @@ process adaptor_removal { ...@@ -17,7 +17,7 @@ process adaptor_removal {
tuple val(file_id), path(reads) tuple val(file_id), path(reads)
output: output:
tuple val(file_id), path("*_cut_R{1,2}.fastq.gz"), emit: fastq tuple val(file_id), path("*_cut_*"), emit: fastq
path "*_report.txt", emit: report path "*_report.txt", emit: report
script: script:
...@@ -29,14 +29,14 @@ process adaptor_removal { ...@@ -29,14 +29,14 @@ process adaptor_removal {
if (reads.size() == 2) if (reads.size() == 2)
""" """
cutadapt ${params.adaptor_removal} \ cutadapt ${params.adaptor_removal} \
-o ${file_id}_cut_R1.fastq.gz -p ${file_id}_cut_R2.fastq.gz \ -o ${file_prefix}_cut_R1.fastq.gz -p ${file_prefix}_cut_R2.fastq.gz \
${reads[0]} ${reads[1]} > ${file_id}_report.txt ${reads[0]} ${reads[1]} > ${file_prefix}_report.txt
""" """
else else
""" """
cutadapt ${params.adaptor_removal} \ cutadapt ${params.adaptor_removal} \
-o ${file_id}_cut.fastq.gz \ -o ${file_prefix}_cut.fastq.gz \
${reads} > ${file_id}_report.txt ${reads} > ${file_prefix}_report.txt
""" """
} }
...@@ -55,7 +55,7 @@ process trimming { ...@@ -55,7 +55,7 @@ process trimming {
tuple val(file_id), path(reads) tuple val(file_id), path(reads)
output: output:
tuple val(file_id), path("*_trim_R{1,2}.fastq.gz"), emit:fastq tuple val(file_id), path("*_trim_*"), emit:fastq
path "*_report.txt", emit: report path "*_report.txt", emit: report
script: script:
...@@ -67,13 +67,13 @@ process trimming { ...@@ -67,13 +67,13 @@ process trimming {
if (reads.size() == 2) if (reads.size() == 2)
""" """
cutadapt ${params.trimming} \ cutadapt ${params.trimming} \
-o ${file_id}_trim_R1.fastq.gz -p ${file_id}_trim_R2.fastq.gz \ -o ${file_prefix}_trim_R1.fastq.gz -p ${file_prefix}_trim_R2.fastq.gz \
${reads[0]} ${reads[1]} > ${file_id}_report.txt ${reads[0]} ${reads[1]} > ${file_prefix}_report.txt
""" """
else else
""" """
cutadapt ${params.trimming} \ cutadapt ${params.trimming} \
-o ${file_id}_trim.fastq.gz \ -o ${file_prefix}_trim.fastq.gz \
${reads} > ${file_id}_report.txt ${reads} > ${file_prefix}_report.txt
""" """
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment