Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions modules/nf-core/trimgalore/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ channels:
- bioconda
dependencies:
- bioconda::trim-galore=0.6.10
- bioconda::cutadapt=5.2
6 changes: 6 additions & 0 deletions modules/nf-core/trimgalore/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ process TRIMGALORE {
def args_list = args.split("\\s(?=--)").toList()
args_list.removeAll { arg -> arg.toLowerCase().contains('_r2 ') }
"""
# Remove any trim_galore outputs left behind by a previous attempt that
# ran in this same workdir (e.g. AWS Batch retry after a Spot reclaim).
rm -f *.fq.gz *.html *.zip *_trimming_report.txt
[ ! -f ${prefix}.fastq.gz ] && ln -s ${reads} ${prefix}.fastq.gz
trim_galore \\
${args_list.join(' ')} \\
Expand All @@ -56,6 +59,9 @@ process TRIMGALORE {
}
else {
"""
# Remove any trim_galore outputs left behind by a previous attempt that
# ran in this same workdir (e.g. AWS Batch retry after a Spot reclaim).
rm -f *.fq.gz *.html *.zip *_trimming_report.txt
[ ! -f ${prefix}_1.fastq.gz ] && ln -s ${reads[0]} ${prefix}_1.fastq.gz
[ ! -f ${prefix}_2.fastq.gz ] && ln -s ${reads[1]} ${prefix}_2.fastq.gz
trim_galore \\
Expand Down
10 changes: 5 additions & 5 deletions modules/nf-core/trimgalore/tests/main.nf.test
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ nextflow_process {
{ assert snapshot(
process.out.reads,
file(process.out.log[0][1]).readLines()[0..9], // line 11 changes
file(process.out.log[0][1]).readLines()[11..59],
file(process.out.log[0][1]).readLines()[11..59].findAll { !it.startsWith("This is cutadapt") }, // strip python version
process.out.findAll { key, val -> key.startsWith("versions")}
).match() }
)
Expand Down Expand Up @@ -56,9 +56,9 @@ nextflow_process {
process.out.reads[0][1][0],
process.out.reads[0][1][1],
file(process.out.log[0][1][0]).readLines()[0..9], // line 11 changes
file(process.out.log[0][1][0]).readLines()[11..58],
file(process.out.log[0][1][0]).readLines()[11..58].findAll { !it.startsWith("This is cutadapt") }, // strip python version
file(process.out.log[0][1][1]).readLines()[0..9], // line 11 changes
file(process.out.log[0][1][1]).readLines()[11..60],
file(process.out.log[0][1][1]).readLines()[11..60].findAll { !it.startsWith("This is cutadapt") }, // strip python version
process.out.findAll { key, val -> key.startsWith("versions")}
).match() }
)
Expand Down Expand Up @@ -95,9 +95,9 @@ nextflow_process {
process.out.unpaired[0][1][0],
process.out.unpaired[0][1][1],
file(process.out.log[0][1][0]).readLines()[0..9], // line 11 changes
file(process.out.log[0][1][0]).readLines()[11..59],
file(process.out.log[0][1][0]).readLines()[11..59].findAll { !it.startsWith("This is cutadapt") }, // strip python version
file(process.out.log[0][1][1]).readLines()[0..9], // line 11 changes
file(process.out.log[0][1][1]).readLines()[11..63],
file(process.out.log[0][1][1]).readLines()[11..63].findAll { !it.startsWith("This is cutadapt") }, // strip python version
process.out.findAll { key, val -> key.startsWith("versions")}
).match() }
)
Expand Down
5 changes: 0 additions & 5 deletions modules/nf-core/trimgalore/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@
"Output file will be GZIP compressed",
"",
"",
"This is cutadapt 5.2 with Python 3.12.12",
"Command line parameters: -j 1 -e 0.1 -q 20 -O 1 -a AGATCGGAAGAGC test_1.fastq.gz",
"Processing single-end reads on 1 core ...",
"",
Expand Down Expand Up @@ -133,7 +132,6 @@
"Output file will be GZIP compressed",
"",
"",
"This is cutadapt 5.2 with Python 3.12.12",
"Command line parameters: -j 1 -e 0.1 -q 20 -O 1 -a AGATCGGAAGAGC test_2.fastq.gz",
"Processing single-end reads on 1 core ...",
"",
Expand Down Expand Up @@ -254,7 +252,6 @@
"Output file will be GZIP compressed",
"",
"",
"This is cutadapt 5.2 with Python 3.12.12",
"Command line parameters: -j 1 -e 0.1 -q 20 -O 1 -a AGATCGGAAGAGC test_1.fastq.gz",
"Processing single-end reads on 1 core ...",
"",
Expand Down Expand Up @@ -316,7 +313,6 @@
"Output file will be GZIP compressed",
"",
"",
"This is cutadapt 5.2 with Python 3.12.12",
"Command line parameters: -j 1 -e 0.1 -q 20 -O 1 -a AGATCGGAAGAGC test_2.fastq.gz",
"Processing single-end reads on 1 core ...",
"",
Expand Down Expand Up @@ -407,7 +403,6 @@
"Output file will be GZIP compressed",
"",
"",
"This is cutadapt 5.2 with Python 3.12.12",
"Command line parameters: -j 1 -e 0.1 -q 20 -O 1 -a AGATCGGAAGAGC test.fastq.gz",
"Processing single-end reads on 1 core ...",
"",
Expand Down
Loading