```
-This will skip all QC-related processes (metrics collection, `Qualimap`)
+This will skip all QC-related processes (picard metrics collection)
#### Skipping visualisation
@@ -299,11 +293,24 @@ There are two parameters to increase the `--limitSjdbInsertNsj` parameter if nec
- `--fusioncatcher_limitSjdbInsertNsj`, default: 2000000
- `--fusioninspector_limitSjdbInsertNsj`, default: 1000000
-Use the parameter `--cram` to compress the BAM files to CRAM for specific tools. Options: arriba, squid, starfusion. Leave no space between options:
+Use the parameter `--cram` to compress the BAM files to CRAM for specific tools. Options: arriba, starfusion. Leave no space between options:
-- `--cram arriba,squid,starfusion`, default: []
+- `--cram arriba,starfusion`, default: []
- `--cram arriba`
+### Troubleshooting
+
+#### GstrandBit issues
+
+The issue below sometimes occurs:
+
+```
+EXITING because of FATAL ERROR: cannot insert sequence on the fly because of strand GstrandBit problem
+SOLUTION: please contact STAR author at https://groups.google.com/forum/#!forum/rna-star
+```
+
+As the error message suggests, it is a STAR-related error and your best luck in solving it will be the forum.
+
### Updating the pipeline
When you run the above command, Nextflow automatically pulls the pipeline code from GitHub and stores it as a cached version. When running the pipeline after this, it will always use the cached version if available - even if the pipeline has been updated since. To make sure that you're running the latest version of the pipeline, make sure that you regularly update the cached version of the pipeline:
@@ -322,11 +329,15 @@ This version number will be logged in reports when you run the pipeline, so that
To further assist in reproducbility, you can use share and re-use [parameter files](#running-the-pipeline) to repeat pipeline runs with the same settings without having to write out a command with every single parameter.
-> 💡 If you wish to share such profile (such as upload as supplementary material for academic publications), make sure to NOT include cluster specific paths to files, nor institutional specific profiles.
+:::tip
+If you wish to share such profile (such as upload as supplementary material for academic publications), make sure to NOT include cluster specific paths to files, nor institutional specific profiles.
+:::
## Core Nextflow arguments
-> **NB:** These options are part of Nextflow and use a _single_ hyphen (pipeline parameters use a double-hyphen).
+:::note
+These options are part of Nextflow and use a _single_ hyphen (pipeline parameters use a double-hyphen).
+:::
### `-profile`
@@ -334,7 +345,9 @@ Use this parameter to choose a configuration profile. Profiles can give configur
Several generic profiles are bundled with the pipeline which instruct the pipeline to use software packaged using different methods (Docker, Singularity, Podman, Shifter, Charliecloud, Apptainer, Conda) - see below.
-> We highly recommend the use of Docker or Singularity containers for full pipeline reproducibility, however when this is not possible, Conda is also supported.
+:::info
+We highly recommend the use of Docker or Singularity containers for full pipeline reproducibility, however when this is not possible, Conda is also supported.
+:::
The pipeline also dynamically loads configurations from [https://github.com/nf-core/configs](https://github.com/nf-core/configs) when it runs, making multiple config profiles for various institutional clusters available at run time. For more information and to see if your system is available in these configs please see the [nf-core/configs documentation](https://github.com/nf-core/configs#documentation).
diff --git a/lib/NfcoreTemplate.groovy b/lib/NfcoreTemplate.groovy
index 408951ae..01b8653d 100755
--- a/lib/NfcoreTemplate.groovy
+++ b/lib/NfcoreTemplate.groovy
@@ -3,6 +3,7 @@
//
import org.yaml.snakeyaml.Yaml
+import groovy.json.JsonOutput
class NfcoreTemplate {
@@ -222,6 +223,21 @@ class NfcoreTemplate {
}
}
+ //
+ // Dump pipeline parameters in a json file
+ //
+ public static void dump_parameters(workflow, params) {
+ def output_d = new File("${params.outdir}/pipeline_info/")
+ if (!output_d.exists()) {
+ output_d.mkdirs()
+ }
+
+ def timestamp = new java.util.Date().format( 'yyyy-MM-dd_HH-mm-ss')
+ def output_pf = new File(output_d, "params_${timestamp}.json")
+ def jsonStr = JsonOutput.toJson(params)
+ output_pf.text = JsonOutput.prettyPrint(jsonStr)
+ }
+
//
// Print pipeline summary on completion
//
diff --git a/lib/WorkflowRnafusion.groovy b/lib/WorkflowRnafusion.groovy
index 0654f5fc..1e289fdc 100755
--- a/lib/WorkflowRnafusion.groovy
+++ b/lib/WorkflowRnafusion.groovy
@@ -53,7 +53,7 @@ class WorkflowRnafusion {
public static String toolCitationText(params) {
- // TODO Optionally add in-text citation tools to this list.
+ // TODO nf-core: Optionally add in-text citation tools to this list.
// Can use ternary operators to dynamically construct based conditions, e.g. params["run_xyz"] ? "Tool (Foo et al. 2023)" : "",
// Uncomment function in methodsDescriptionText to render in MultiQC report
def citation_text = [
diff --git a/main.nf b/main.nf
index 07b9c174..520bcff7 100644
--- a/main.nf
+++ b/main.nf
@@ -23,7 +23,7 @@ params.gtf = WorkflowMain.getGenomeAttribute(params, 'gtf')
params.chrgtf = WorkflowMain.getGenomeAttribute(params, 'chrgtf')
params.transcript = WorkflowMain.getGenomeAttribute(params, 'transcript')
params.refflat = WorkflowMain.getGenomeAttribute(params, 'refflat')
-params.rrna_intervals = WorkflowMain.getGenomeAttribute(params, 'rrna_intervals')
+params.rrna_intervals = WorkflowMain.getGenomeAttribute(params, 'rrna_intervals')
/*
========================================================================================
@@ -31,7 +31,6 @@ params.rrna_intervals = WorkflowMain.getGenomeAttribute(params, 'rrna_interval
========================================================================================
*/
-
/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
VALIDATE & PRINT PARAMETER SUMMARY
diff --git a/modules.json b/modules.json
index 162a71b5..345e65b8 100644
--- a/modules.json
+++ b/modules.json
@@ -5,6 +5,11 @@
"https://github.com/nf-core/modules.git": {
"modules": {
"nf-core": {
+ "agat/convertspgff2tsv": {
+ "branch": "master",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
+ "installed_by": ["modules"]
+ },
"arriba": {
"branch": "master",
"git_sha": "ea9e2892a9d12e8769402f12096219942bcf6536",
@@ -12,102 +17,97 @@
},
"cat/cat": {
"branch": "master",
- "git_sha": "911696ea0b62df80e900ef244d7867d177971f73",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"cat/fastq": {
"branch": "master",
- "git_sha": "5c460c5a4736974abde2843294f35307ee2b0e5e",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"custom/dumpsoftwareversions": {
"branch": "master",
- "git_sha": "05c280924b6c768d484c7c443dad5e605c4ff4b4",
+ "git_sha": "bba7e362e4afead70653f84d8700588ea28d0f9e",
"installed_by": ["modules"]
},
"fastp": {
"branch": "master",
- "git_sha": "d497a4868ace3302016ea8ed4b395072d5e833cd",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"fastqc": {
"branch": "master",
- "git_sha": "9a4517e720bc812e95b56d23d15a1653b6db4f53",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"gatk4/bedtointervallist": {
"branch": "master",
- "git_sha": "2df2a11d5b12f2a73bca74f103691bc35d83c5fd",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"gatk4/createsequencedictionary": {
"branch": "master",
- "git_sha": "541811d779026c5d395925895fa5ed35e7216cc0",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
- "kallisto/index": {
+ "gatk4/markduplicates": {
"branch": "master",
- "git_sha": "699fa6f3002d922380615f3847198aeb57d8b6a9",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"multiqc": {
"branch": "master",
- "git_sha": "a6e11ac655e744f7ebc724be669dd568ffdc0e80",
- "installed_by": ["modules"]
- },
- "picard/collectwgsmetrics": {
- "branch": "master",
- "git_sha": "735e1e04e7e01751d2d6e97055bbdb6f70683cc1",
+ "git_sha": "1537442a7be4a78efa3d1ff700a923c627bbda5d",
"installed_by": ["modules"]
},
- "picard/markduplicates": {
+ "picard/collectinsertsizemetrics": {
"branch": "master",
- "git_sha": "2ee934606f1fdf7fc1cb05d6e8abc13bec8ab448",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
- "qualimap/rnaseq": {
+ "picard/collectwgsmetrics": {
"branch": "master",
- "git_sha": "4657d98bc9f565e067c4d924126ce107056f5e2f",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"samtools/faidx": {
"branch": "master",
- "git_sha": "fd742419940e01ba1c5ecb172c3e32ec840662fe",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"samtools/index": {
"branch": "master",
- "git_sha": "911696ea0b62df80e900ef244d7867d177971f73",
+ "git_sha": "5394565c5fe4c760e5b35977ec7607c62e81d1f8",
"installed_by": ["modules"]
},
"samtools/sort": {
"branch": "master",
- "git_sha": "a0f7be95788366c1923171e358da7d049eb440f9",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"samtools/view": {
"branch": "master",
- "git_sha": "3ffae3598260a99e8db3207dead9f73f87f90d1f",
+ "git_sha": "3f5420aa22e00bd030a2556dfdffc9e164ec0ec5",
"installed_by": ["modules"]
},
"star/align": {
"branch": "master",
- "git_sha": "cc08a888069f67cab8120259bddab8032d4c0fe3",
+ "git_sha": "9f6b233518f7d9ecdcf24b798b7e491db5424273",
"installed_by": ["modules"]
},
"star/genomegenerate": {
"branch": "master",
- "git_sha": "cc08a888069f67cab8120259bddab8032d4c0fe3",
+ "git_sha": "0e98289b5bec6e3f8f588a8a9d05e8aacc1179a0",
"installed_by": ["modules"]
},
"stringtie/merge": {
"branch": "master",
- "git_sha": "911696ea0b62df80e900ef244d7867d177971f73",
+ "git_sha": "b0dcb44b018d9b2bcb35b1abb7bcd34061bc5a6d",
"installed_by": ["modules"]
},
"stringtie/stringtie": {
"branch": "master",
- "git_sha": "911696ea0b62df80e900ef244d7867d177971f73",
+ "git_sha": "b0dcb44b018d9b2bcb35b1abb7bcd34061bc5a6d",
"installed_by": ["modules"]
}
}
diff --git a/modules/local/arriba/download/main.nf b/modules/local/arriba/download/main.nf
index 166ed69f..860439ad 100644
--- a/modules/local/arriba/download/main.nf
+++ b/modules/local/arriba/download/main.nf
@@ -13,11 +13,11 @@ process ARRIBA_DOWNLOAD {
script:
"""
- wget https://github.com/suhrig/arriba/releases/download/v2.3.0/arriba_v2.3.0.tar.gz -O arriba_v2.3.0.tar.gz
- tar -xzvf arriba_v2.3.0.tar.gz
- rm arriba_v2.3.0.tar.gz
- mv arriba_v2.3.0/database/* .
- rm -r arriba_v2.3.0
+ wget https://github.com/suhrig/arriba/releases/download/v2.4.0/arriba_v2.4.0.tar.gz -O arriba_v2.4.0.tar.gz
+ tar -xzvf arriba_v2.4.0.tar.gz
+ rm arriba_v2.4.0.tar.gz
+ mv arriba_v2.4.0/database/* .
+ rm -r arriba_v2.4.0
cat <<-END_VERSIONS > versions.yml
"${task.process}":
@@ -27,11 +27,11 @@ process ARRIBA_DOWNLOAD {
stub:
"""
- touch blacklist_hg38_GRCh38_v2.3.0.tsv.gz
- touch protein_domains_hg38_GRCh38_v2.3.0.gff3
- touch cytobands_hg38_GRCh38_v2.3.0.tsv
- touch known_fusions_hg38_GRCh38_v2.3.0.tsv.gz
- touch protein_domains_hg38_GRCh38_v2.3.0.gff3
+ touch blacklist_hg38_GRCh38_v2.4.0.tsv.gz
+ touch protein_domains_hg38_GRCh38_v2.4.0.gff3
+ touch cytobands_hg38_GRCh38_v2.4.0.tsv
+ touch known_fusions_hg38_GRCh38_v2.4.0.tsv.gz
+ touch protein_domains_hg38_GRCh38_v2.4.0.gff3
cat <<-END_VERSIONS > versions.yml
"${task.process}":
diff --git a/modules/local/arriba/visualisation/main.nf b/modules/local/arriba/visualisation/main.nf
index 5805a904..cc120119 100644
--- a/modules/local/arriba/visualisation/main.nf
+++ b/modules/local/arriba/visualisation/main.nf
@@ -2,10 +2,10 @@ process ARRIBA_VISUALISATION {
tag "$meta.id"
label 'process_medium'
- conda "bioconda::arriba=2.3.0"
+ conda "bioconda::arriba=2.4.0"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/arriba:2.3.0--haa8aa89_0' :
- 'quay.io/biocontainers/arriba:2.3.0--haa8aa89_0' }"
+ 'https://depot.galaxyproject.org/singularity/arriba:2.4.0--h0033a41_2' :
+ 'biocontainers/arriba:2.4.0--h0033a41_2' }"
input:
tuple val(meta), path(bam), path(bai), path(fusions)
diff --git a/modules/local/fusioninspector/main.nf b/modules/local/fusioninspector/main.nf
index 6f59a590..c7fcd3f0 100644
--- a/modules/local/fusioninspector/main.nf
+++ b/modules/local/fusioninspector/main.nf
@@ -10,9 +10,11 @@ process FUSIONINSPECTOR {
path reference
output:
- tuple val(meta), path("*FusionInspector.fusions.tsv") , emit: tsv
- path "*" , emit: output
- path "versions.yml" , emit: versions
+ tuple val(meta), path("*FusionInspector.fusions.tsv") , emit: tsv
+ tuple val(meta), path("*.coding_effect") , optional:true, emit: tsv_coding_effect
+ tuple val(meta), path("*.gtf") , optional:true, emit: out_gtf
+ path "*" , emit: output
+ path "versions.yml" , emit: versions
when:
task.ext.when == null || task.ext.when
@@ -21,6 +23,7 @@ process FUSIONINSPECTOR {
def prefix = task.ext.prefix ?: "${meta.id}"
def fasta = meta.single_end ? "--left_fq ${reads[0]}" : "--left_fq ${reads[0]} --right_fq ${reads[1]}"
def args = task.ext.args ?: ''
+ def args2 = task.ext.args2 ?: ''
"""
FusionInspector \\
--fusions $fusion_list \\
@@ -29,7 +32,7 @@ process FUSIONINSPECTOR {
--CPU ${task.cpus} \\
-O . \\
--out_prefix $prefix \\
- --vis $args
+ --vis $args $args2
cat <<-END_VERSIONS > versions.yml
"${task.process}":
@@ -38,9 +41,12 @@ process FUSIONINSPECTOR {
"""
stub:
+ def prefix = task.ext.prefix ?: "${meta.id}"
"""
- touch FusionInspector.log
- touch FusionInspector.fusions.tsv
+ touch ${prefix}.FusionInspector.log
+ touch ${prefix}.FusionInspector.fusions.tsv
+ touch ${prefix}.FusionInspector.fusions.tsv.annotated.coding_effect
+ touch ${prefix}.gtf
cat <<-END_VERSIONS > versions.yml
"${task.process}":
diff --git a/modules/local/fusionreport/detect/main.nf b/modules/local/fusionreport/detect/main.nf
index 38809803..8024d8f8 100644
--- a/modules/local/fusionreport/detect/main.nf
+++ b/modules/local/fusionreport/detect/main.nf
@@ -2,14 +2,14 @@ process FUSIONREPORT {
tag "$meta.id"
label 'process_medium'
- // Note: 2.7X indices incompatible with AWS iGenomes.
conda "bioconda::star=2.7.9a"
- container "docker.io/clinicalgenomics/fusion-report:2.1.5p4"
+ container "docker.io/clinicalgenomics/fusion-report:2.1.8"
input:
- tuple val(meta), path(reads), path(arriba_fusions), path(pizzly_fusions), path(squid_fusions), path(starfusion_fusions), path(fusioncatcher_fusions)
+ tuple val(meta), path(reads), path(arriba_fusions), path(starfusion_fusions), path(fusioncatcher_fusions)
tuple val(meta2), path(fusionreport_ref)
+ val(tools_cutoff)
output:
path "versions.yml" , emit: versions
@@ -27,13 +27,11 @@ process FUSIONREPORT {
def args = task.ext.args ?: ''
def args2 = task.ext.args2 ?: ''
def tools = params.arriba || params.all ? "--arriba ${arriba_fusions} " : ''
- tools += params.pizzly || params.all ? "--pizzly ${pizzly_fusions} " : ''
- tools += params.squid || params.all ? "--squid ${squid_fusions} " : ''
tools += params.starfusion || params.all ? "--starfusion ${starfusion_fusions} " : ''
tools += params.fusioncatcher || params.all ? "--fusioncatcher ${fusioncatcher_fusions} " : ''
def prefix = task.ext.prefix ?: "${meta.id}"
"""
- fusion_report run $meta.id . $fusionreport_ref $tools --allow-multiple-gene-symbols $args $args2
+ fusion_report run $meta.id . $fusionreport_ref $tools --allow-multiple-gene-symbols --tool-cutoff $tools_cutoff $args $args2
mv fusion_list.tsv ${prefix}.fusionreport.tsv
mv fusion_list_filtered.tsv ${prefix}.fusionreport_filtered.tsv
diff --git a/modules/local/fusionreport/detect/meta.yml b/modules/local/fusionreport/detect/meta.yml
index 7b9de84c..ae3601dc 100644
--- a/modules/local/fusionreport/detect/meta.yml
+++ b/modules/local/fusionreport/detect/meta.yml
@@ -5,7 +5,7 @@ keywords:
tools:
- fusionreport:
description: Tool for parsing outputs from fusion detection tools
- homepage: https://github.com/matq007/fusion-report
+ homepage: https://github.com/Clinical-Genomics/fusion-report
documentation: https://matq007.github.io/fusion-report/#/
doi: "10.1101/011650"
licence: ["GPL v3"]
@@ -24,14 +24,6 @@ input:
type: path
description: File
pattern: "*.fusions.tsv"
- - pizzly_fusions:
- type: path
- description: File containing fusions from pizzly
- pattern: "*.pizzly.txt"
- - squid_fusions:
- type: path
- description: File containing fusions from squid
- pattern: "*.annotated.txt"
- starfusion_fusions:
type: path
description: File containing fusions from STARfusion
diff --git a/modules/local/fusionreport/download/main.nf b/modules/local/fusionreport/download/main.nf
index 3ab1bc03..ac288ade 100644
--- a/modules/local/fusionreport/download/main.nf
+++ b/modules/local/fusionreport/download/main.nf
@@ -2,9 +2,8 @@ process FUSIONREPORT_DOWNLOAD {
tag 'fusionreport'
label 'process_medium'
- // Note: 2.7X indices incompatible with AWS iGenomes.
conda "bioconda::star=2.7.9a"
- container "docker.io/clinicalgenomics/fusion-report:2.1.5p4"
+ container "docker.io/clinicalgenomics/fusion-report:2.1.8"
input:
val(username)
diff --git a/modules/local/hgnc/main.nf b/modules/local/hgnc/main.nf
new file mode 100644
index 00000000..1b3808f6
--- /dev/null
+++ b/modules/local/hgnc/main.nf
@@ -0,0 +1,41 @@
+process HGNC_DOWNLOAD {
+ tag "hgnc"
+ label 'process_low'
+
+ conda "bioconda::gnu-wget=1.18"
+ container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
+ 'https://depot.galaxyproject.org/singularity/gnu-wget:1.18--h5bf99c6_5' :
+ 'quay.io/biocontainers/gnu-wget:1.18--h5bf99c6_5' }"
+
+ input:
+
+ output:
+ path "hgnc_complete_set.txt" , emit: hgnc_ref
+ path "HGNC-DB-timestamp.txt" , emit: hgnc_date
+
+ path "versions.yml" , emit: versions
+
+
+ script:
+ """
+ wget https://ftp.ebi.ac.uk/pub/databases/genenames/hgnc/tsv/hgnc_complete_set.txt
+ date +%Y-%m-%d/%H:%M > HGNC-DB-timestamp.txt
+
+ cat <<-END_VERSIONS > versions.yml
+ "${task.process}":
+ wget: \$(echo wget -V 2>&1 | grep "GNU Wget" | cut -d" " -f3 > versions.yml)
+ END_VERSIONS
+ """
+
+ stub:
+ """
+ touch "hgnc_complete_set.txt"
+ touch "HGNC-DB-timestamp.txt"
+
+ cat <<-END_VERSIONS > versions.yml
+ "${task.process}":
+ wget: \$(echo wget -V 2>&1 | grep "GNU Wget" | cut -d" " -f3 > versions.yml)
+ END_VERSIONS
+ """
+
+}
diff --git a/modules/local/kallisto/quant/main.nf b/modules/local/kallisto/quant/main.nf
deleted file mode 100644
index 7d3e5dfb..00000000
--- a/modules/local/kallisto/quant/main.nf
+++ /dev/null
@@ -1,47 +0,0 @@
-process KALLISTO_QUANT {
- tag "$meta.id"
- label 'process_medium'
-
- conda "bioconda::kallisto=0.46.2"
- container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/kallisto:0.46.2--h4f7b962_1' :
- 'quay.io/biocontainers/kallisto:0.46.2--h4f7b962_1' }"
-
-
- input:
- tuple val(meta), path(reads)
- path index
-
- output:
- path "versions.yml" , emit: versions
- tuple val(meta), path("*fusions.txt") , emit: txt
-
- script:
- def args = task.ext.args ?: ''
- def prefix = task.ext.prefix ?: "${meta.id}"
- """
- kallisto quant \
- -t $task.cpus \
- -i $index \
- --fusion \
- -o . \
- $reads
- mv fusion.txt ${prefix}.kallisto_quant.fusions.txt
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- kallisto: \$(echo \$(kallisto 2>&1) | sed 's/^kallisto //; s/Usage.*\$//')
- END_VERSIONS
- """
-
- stub:
- def prefix = task.ext.prefix ?: "${meta.id}"
- """
- touch ${prefix}.kallisto_quant.fusions.txt
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- kallisto: \$(echo \$(kallisto 2>&1) | sed 's/^kallisto //; s/Usage.*\$//')
- END_VERSIONS
- """
-}
-
diff --git a/modules/local/kallisto/quant/meta.yml b/modules/local/kallisto/quant/meta.yml
deleted file mode 100644
index 31821aa6..00000000
--- a/modules/local/kallisto/quant/meta.yml
+++ /dev/null
@@ -1,44 +0,0 @@
-name: kallisto_quant
-description: runs the kallisto quantification algorithm
- - quant
-tools:
- - kallisto:
- description: Quantifying abundances of transcripts from bulk and single-cell RNA-Seq data, or more generally of target sequences using high-throughput sequencing reads.
- homepage: https://pachterlab.github.io/kallisto/
- documentation: https://pachterlab.github.io/kallisto/manual
- tool_dev_url: https://github.com/pachterlab/kallisto
- doi: ""
- licence: ["BSD-2-Clause"]
-
-input:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - reads:
- type: file
- description: FASTQ file
- pattern: "*.{fastq}"
- - reference:
- type: directory
- description: Path to kallisto index
- pattern: "*"
-
-output:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - versions:
- type: file
- description: File containing software versions
- pattern: "versions.yml"
- - fusions:
- type: file
- description: fusions
- pattern: "*.txt"
-
-authors:
- - "@rannick"
diff --git a/modules/local/pizzly/detect/main.nf b/modules/local/pizzly/detect/main.nf
deleted file mode 100644
index a610b531..00000000
--- a/modules/local/pizzly/detect/main.nf
+++ /dev/null
@@ -1,49 +0,0 @@
-process PIZZLY {
- tag "$meta.id"
- label 'process_medium'
-
- conda "bioconda::kallisto=0.46.2 bioconda::pizzly==0.37.3"
- container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/pizzly:0.37.3--py36_2' :
- 'quay.io/biocontainers/pizzly:0.37.3--h470a237_3' }"
-
- input:
- tuple val(meta), path(txt)
- tuple val(meta2), path(transcript)
- tuple val(meta3), path(gtf)
-
- output:
- path "versions.yml" , emit: versions
- tuple val(meta), path("*pizzly.txt") , emit: fusions
- tuple val(meta), path("*unfiltered.json") , emit: fusions_unfiltered
-
- script:
- def args = task.ext.args ?: ''
- def prefix = task.ext.prefix ?: "${meta.id}"
- """
- pizzly \\
- $args \\
- --gtf $gtf \\
- --fasta $transcript \\
- --output ${prefix}.pizzly $txt
-
- pizzly_flatten_json.py ${prefix}.pizzly.json ${prefix}.pizzly.txt
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- pizzly: \$(pizzly --version | grep pizzly | sed -e "s/pizzly version: //g")
- END_VERSIONS
- """
-
- stub:
- def prefix = task.ext.prefix ?: "${meta.id}"
- """
- touch ${prefix}.pizzly.txt
- touch ${prefix}.pizzly.unfiltered.json
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- pizzly: \$(pizzly --version | grep pizzly | sed -e "s/pizzly version: //g")
- END_VERSIONS
- """
-}
-
diff --git a/modules/local/pizzly/detect/meta.yml b/modules/local/pizzly/detect/meta.yml
deleted file mode 100644
index 930b3a62..00000000
--- a/modules/local/pizzly/detect/meta.yml
+++ /dev/null
@@ -1,44 +0,0 @@
-name: pizzly
-description: Pizzly detection of fusions.
-keywords:
- - fusion
- - pizzly
-tools:
- - pizzly:
- description: Fast fusion detection using kallisto
- homepage: https://github.com/pmelsted/pizzly
- documentation: https://github.com/pmelsted/pizzly
- tool_dev_url: https://github.com/pmelsted/pizzly
- doi: ""
- licence: ["BSD-2-Clause"]
-
-input:
- - fasta:
- type: file
- description: genome fasta file
- pattern: "*.{fasta*}"
- - reference:
- type: directory
- description: Path to kallisto index
- pattern: "*"
- - gtf:
- type: file
- description: gtf reference
- pattern: "*.gtf"
-
-output:
- - versions:
- type: file
- description: File containing software versions
- pattern: "versions.yml"
- - fusions:
- type: file
- description: fusions
- pattern: "*pizzly.txt"
- - unfiltered:
- type: file
- description: unfiltered fusions
- pattern: "*unfiltered.json"
-
-authors:
- - "@rannick"
diff --git a/modules/local/pizzly/download/main.nf b/modules/local/pizzly/download/main.nf
deleted file mode 100644
index efaae3aa..00000000
--- a/modules/local/pizzly/download/main.nf
+++ /dev/null
@@ -1,40 +0,0 @@
-process PIZZLY_DOWNLOAD {
- tag "pizzly"
- label 'process_medium'
-
- conda "bioconda::kallisto=0.46.2"
- container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/kallisto:0.46.2--h4f7b962_1' :
- 'quay.io/biocontainers/kallisto:0.46.2--h4f7b962_1' }"
-
- input:
- tuple val(meta), path(transcript)
-
- output:
- path "versions.yml" , emit: versions
- path "index.idx" , emit: reference
-
- script:
- def args = task.ext.args ?: ''
- """
- kallisto index \\
- -i index.idx \\
- $args \\
- $transcript
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- kallisto: \$(echo \$(kallisto 2>&1) | sed 's/^kallisto //; s/Usage.*\$//')
- END_VERSIONS """
-
- stub:
- """
- touch index.idx
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- kallisto: \$(echo \$(kallisto 2>&1) | sed 's/^kallisto //; s/Usage.*\$//')
- END_VERSIONS
- """
-
-}
diff --git a/modules/local/reformat/main.nf b/modules/local/reformat/main.nf
deleted file mode 100644
index 969b0e34..00000000
--- a/modules/local/reformat/main.nf
+++ /dev/null
@@ -1,53 +0,0 @@
-process REFORMAT {
- tag "$meta.id"
- label 'process_medium'
-
- conda "bioconda::bbmap=38.90"
- container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/bbmap:38.90--he522d1c_1' :
- 'quay.io/biocontainers/bbmap:38.90--he522d1c_1' }"
-
-
- input:
- tuple val(meta), path(reads)
-
- output:
- path "versions.yml" , emit: versions
- tuple val(meta), path("*trimmed.fq.gz") , emit: reads_out
-
-
- when:
- task.ext.when == null || task.ext.when
-
- script:
- def args = task.ext.args ?: ''
- def args2 = task.ext.args2 ?: ''
- def prefix = task.ext.prefix ?: "${meta.id}"
- def in1 = "in=${reads[0]}"
- def in2 = meta.single_end ? "" : "in=${reads[1]}"
- def out1 ="out=${prefix}_R1_trimmed.fq.gz"
- def out2 =meta.single_end ? "" : "out=${prefix}_R2_trimmed.fq.gz"
-
- """
- reformat.sh $in1 $out1 $args
- reformat.sh $in2 $out2 $args2
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- reformat.sh: \$(echo \$(reformat.sh --version 2>&1)| sed -e "s/BBMap version //g" )
- END_VERSIONS
- """
-
- stub:
- def prefix = task.ext.prefix ?: "${meta.id}"
- def out1 ="out=${prefix}_R1_trimmed.fq.gz"
- def out2 =meta.single_end ? "" : "out=${prefix}_R2_trimmed.fq.gz"
- """
- touch $out1
- touch $out2
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- reformat.sh: \$(echo \$(reformat.sh --version 2>&1)| sed -e "s/BBMap version //g" )
- END_VERSIONS
- """
-}
diff --git a/modules/local/reformat/meta.yml b/modules/local/reformat/meta.yml
deleted file mode 100644
index 86e0970a..00000000
--- a/modules/local/reformat/meta.yml
+++ /dev/null
@@ -1,40 +0,0 @@
-name: fusionreport
-description: fusionreport
-keywords:
- - sort
-tools:
- - fusionreport:
- description: fusionreport
- homepage: https://github.com/matq007/fusion-report
- documentation: https://matq007.github.io/fusion-report/#/
- doi: "10.1101/011650"
- licence: ["GPL v3"]
-
-input:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - reads:
- type: file
- description: FASTQ file
- pattern: "*.{fastq}*"
-
-output:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - versions:
- type: file
- description: File containing software versions
- pattern: "versions.yml"
- - reads:
- type: file
- description: FASTQ file
- pattern: "*.{fq.gz}"
-
-authors:
- - "@praveenraj2018, @rannick"
diff --git a/modules/local/squid/annotate/main.nf b/modules/local/squid/annotate/main.nf
deleted file mode 100644
index 9b6eebe7..00000000
--- a/modules/local/squid/annotate/main.nf
+++ /dev/null
@@ -1,41 +0,0 @@
-
-process SQUID_ANNOTATE {
- tag "$meta.id"
- label 'process_medium'
-
- conda "bioconda::squid=1.5"
- container "docker.io/nfcore/rnafusion:squid_1.5-star2.7.1a"
-
-
-
- input:
- tuple val(meta), path(txt)
- tuple val(meta2), path(gtf)
-
- output:
- tuple val(meta), path("*annotated.txt") , emit: fusions_annotated
- path "versions.yml" , emit: versions
-
-
- script:
- def args = task.ext.args ?: ''
- def prefix = task.ext.prefix ?: "${meta.id}"
- """
- AnnotateSQUIDOutput.py $gtf $txt ${prefix}.squid.fusions.annotated.txt
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- squid: \$(echo \$(squid --version 2>&1) | sed 's/v//')
- END_VERSIONS
- """
-
- stub:
- def prefix = task.ext.prefix ?: "${meta.id}"
- """
- touch ${prefix}.squid.fusions.annotated.txt
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- squid: \$(echo \$(squid --version 2>&1) | sed 's/v//')
- END_VERSIONS
- """
-}
diff --git a/modules/local/squid/annotate/meta.yml b/modules/local/squid/annotate/meta.yml
deleted file mode 100644
index e1a1f0d2..00000000
--- a/modules/local/squid/annotate/meta.yml
+++ /dev/null
@@ -1,36 +0,0 @@
-name: squid
-description: Squid detection of fusions.
-keywords:
- - fusion
- - pizzly
-tools:
- - pizzly:
- description: Fusion detection using squid
- homepage: https://github.com/Kingsford-Group/squid
- documentation: https://github.com/Kingsford-Group/squid
- tool_dev_url: https://github.com/Kingsford-Group/squid
- doi: ""
- licence: ["BSD-3-Clause"]
-
-input:
- - fusions:
- type: directory
- description: Path to squid fusions
- pattern: "*.txt"
- - gtf:
- type: file
- description: gtf reference
- pattern: "*.gtf"
-
-output:
- - versions:
- type: file
- description: File containing software versions
- pattern: "versions.yml"
- - fusions_annotated:
- type: file
- description: squid fusions annotated
- pattern: "*squid.fusions.annotated.txt"
-
-authors:
- - "@rannick"
diff --git a/modules/local/squid/detect/main.nf b/modules/local/squid/detect/main.nf
deleted file mode 100644
index 3ccb6e3e..00000000
--- a/modules/local/squid/detect/main.nf
+++ /dev/null
@@ -1,40 +0,0 @@
-
-process SQUID {
- tag "squid"
- label 'process_medium'
-
- conda "bioconda::squid=1.5"
- container "docker.io/nfcore/rnafusion:squid_1.5-star2.7.1a"
-
-
-
- input:
- tuple val(meta), path(bam), path(chimeric_bam)
-
- output:
- tuple val(meta), path("*sv.txt") , emit: fusions
- path "versions.yml" , emit: versions
-
-
- script:
- def args = task.ext.args ?: ''
- def prefix = task.ext.prefix ?: "${meta.id}"
- """
- squid -b $bam -c $chimeric_bam -o ${prefix}.squid.fusions
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- squid: \$(echo \$(squid --version 2>&1) | sed 's/v//')
- END_VERSIONS
- """
-
- stub:
- def prefix = task.ext.prefix ?: "${meta.id}"
- """
- touch ${prefix}.squid.fusions_sv.txt
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- squid: \$(echo \$(squid --version 2>&1) | sed 's/v//')
- END_VERSIONS
- """
-}
diff --git a/modules/local/squid/detect/meta.yml b/modules/local/squid/detect/meta.yml
deleted file mode 100644
index a7f1e61a..00000000
--- a/modules/local/squid/detect/meta.yml
+++ /dev/null
@@ -1,41 +0,0 @@
-name: squid
-description: Squid detection of fusions.
-keywords:
- - fusion
- - pizzly
-tools:
- - pizzly:
- description: Fusion detection using squid
- homepage: https://github.com/Kingsford-Group/squid
- documentation: https://github.com/Kingsford-Group/squid
- tool_dev_url: https://github.com/Kingsford-Group/squid
- doi: ""
- licence: ["BSD-3-Clause"]
-
-input:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - bam:
- type: file
- description: BAM/CRAM/SAM file
- pattern: "*.{bam,cram,sam}"
- - chimeric_bam:
- type: file
- description: BAM/CRAM/SAM file containing only chimeric sorted reads
- pattern: "*.{bam,cram,sam}"
-
-output:
- - versions:
- type: file
- description: File containing software versions
- pattern: "versions.yml"
- - fusions:
- type: directory
- description: Path to squid fusions
- pattern: "*.txt"
-
-authors:
- - "@rannick"
diff --git a/modules/local/megafusion/main.nf b/modules/local/vcf_collect/main.nf
similarity index 57%
rename from modules/local/megafusion/main.nf
rename to modules/local/vcf_collect/main.nf
index d8cb5db0..3ede7936 100644
--- a/modules/local/megafusion/main.nf
+++ b/modules/local/vcf_collect/main.nf
@@ -1,18 +1,20 @@
-process MEGAFUSION {
+process VCF_COLLECT {
tag "$meta.id"
label 'process_single'
- conda "conda-forge::python=3.8.3"
+ conda "conda-forge::pandas=1.5.2"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/pandas:1.5.2' :
'quay.io/biocontainers/pandas:1.5.2' }"
input:
- tuple val(meta), path(tsv), path(report)
+ tuple val(meta), path(fusioninspector_tsv), path(fusioninspector_gtf_tsv), path(fusionreport_report), path(fusionreport_csv)
+ tuple val(meta2), path(hgnc_ref)
+ tuple val(meta3), path(hgnc_date)
output:
path "versions.yml" , emit: versions
- tuple val(meta), path("*vcf") , emit: vcf
+ tuple val(meta), path("*vcf.gz") , emit: vcf
when:
task.ext.when == null || task.ext.when
@@ -20,11 +22,13 @@ process MEGAFUSION {
script:
def prefix = task.ext.prefix ?: "${meta.id}"
"""
- megafusion.py --fusioninspector $tsv --fusionreport $report --sample ${prefix} --out ${prefix}.vcf
+ vcf_collect.py --fusioninspector $fusioninspector_tsv --fusionreport $fusionreport_report --fusioninspector_gtf $fusioninspector_gtf_tsv --fusionreport_csv $fusionreport_csv --hgnc $hgnc_ref --sample ${prefix} --out ${prefix}_fusion_data.vcf
+ gzip ${prefix}_fusion_data.vcf
cat <<-END_VERSIONS > versions.yml
"${task.process}":
python: \$(python --version | sed 's/Python //g')
+ HGNC DB retrieval: \$(cat $hgnc_date)
END_VERSIONS
"""
diff --git a/modules/local/megafusion/meta.yml b/modules/local/vcf_collect/meta.yml
similarity index 90%
rename from modules/local/megafusion/meta.yml
rename to modules/local/vcf_collect/meta.yml
index 31343c7e..de4667bb 100644
--- a/modules/local/megafusion/meta.yml
+++ b/modules/local/vcf_collect/meta.yml
@@ -1,5 +1,5 @@
-name: megafusion
-description: megafusion
+name: vcf_collect
+description: vcf_collect
keywords:
- sort
tools:
@@ -32,8 +32,8 @@ output:
pattern: "versions.yml"
- vcf:
type: file
- description: File containing the summary of all fusions as vcf file
- pattern: "*.tsv"
+ description: File containing the summary of all fusions as compressed vcf file
+ pattern: "*.vcf.gz"
authors:
- "@rannick"
diff --git a/modules/nf-core/agat/convertspgff2tsv/environment.yml b/modules/nf-core/agat/convertspgff2tsv/environment.yml
new file mode 100644
index 00000000..b5fdf3db
--- /dev/null
+++ b/modules/nf-core/agat/convertspgff2tsv/environment.yml
@@ -0,0 +1,7 @@
+name: agat_convertspgff2tsv
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::agat=1.2.0
diff --git a/modules/nf-core/agat/convertspgff2tsv/main.nf b/modules/nf-core/agat/convertspgff2tsv/main.nf
new file mode 100644
index 00000000..cef48360
--- /dev/null
+++ b/modules/nf-core/agat/convertspgff2tsv/main.nf
@@ -0,0 +1,35 @@
+process AGAT_CONVERTSPGFF2TSV {
+ tag "$meta.id"
+ label 'process_single'
+
+ conda "${moduleDir}/environment.yml"
+ container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
+ 'https://depot.galaxyproject.org/singularity/agat:1.2.0--pl5321hdfd78af_0' :
+ 'biocontainers/agat:1.2.0--pl5321hdfd78af_0' }"
+
+ input:
+ tuple val(meta), path(gff)
+
+ output:
+ tuple val(meta), path("*.tsv"), emit: tsv
+ path "versions.yml" , emit: versions
+
+ when:
+ task.ext.when == null || task.ext.when
+
+ script:
+ def args = task.ext.args ?: ''
+ def prefix = task.ext.prefix ?: "${meta.id}"
+
+ """
+ agat_convert_sp_gff2tsv.pl \\
+ --gff $gff \\
+ --output ${prefix}.tsv \\
+ $args
+
+ cat <<-END_VERSIONS > versions.yml
+ "${task.process}":
+ agat: \$(agat_convert_sp_gff2tsv.pl --help | sed '3!d; s/.*v//' | sed 's/ .*//')
+ END_VERSIONS
+ """
+}
diff --git a/modules/nf-core/agat/convertspgff2tsv/meta.yml b/modules/nf-core/agat/convertspgff2tsv/meta.yml
new file mode 100644
index 00000000..f5865dfe
--- /dev/null
+++ b/modules/nf-core/agat/convertspgff2tsv/meta.yml
@@ -0,0 +1,38 @@
+name: agat_convertspgff2tsv
+description: |
+ Converts a GFF/GTF file into a TSV file
+keywords:
+ - genome
+ - gff
+ - gtf
+ - conversion
+ - tsv
+tools:
+ - agat:
+ description: "AGAT is a toolkit for manipulation and getting information from GFF/GTF files"
+ homepage: "https://github.com/NBISweden/AGAT"
+ documentation: "https://agat.readthedocs.io/"
+ tool_dev_url: "https://github.com/NBISweden/AGAT"
+ doi: "10.5281/zenodo.3552717"
+ licence: ["GPL v3"]
+input:
+ - meta:
+ type: map
+ description: |
+ Groovy Map containing sample information
+ e.g. [ id:'test', single_end:false ]
+ - gff:
+ type: file
+ description: Annotation file in GFF3/GTF format
+ pattern: "*.{gff, gtf}"
+output:
+ - tsv:
+ type: file
+ description: Annotation file in TSV format
+ pattern: "*.{gtf}"
+ - versions:
+ type: file
+ description: File containing software versions
+ pattern: "versions.yml"
+authors:
+ - "@rannick"
diff --git a/modules/nf-core/cat/cat/environment.yml b/modules/nf-core/cat/cat/environment.yml
new file mode 100644
index 00000000..17a04ef2
--- /dev/null
+++ b/modules/nf-core/cat/cat/environment.yml
@@ -0,0 +1,7 @@
+name: cat_cat
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - conda-forge::pigz=2.3.4
diff --git a/modules/nf-core/cat/cat/main.nf b/modules/nf-core/cat/cat/main.nf
index 9f062219..4264a92c 100644
--- a/modules/nf-core/cat/cat/main.nf
+++ b/modules/nf-core/cat/cat/main.nf
@@ -2,7 +2,7 @@ process CAT_CAT {
tag "$meta.id"
label 'process_low'
- conda "conda-forge::pigz=2.3.4"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/pigz:2.3.4' :
'biocontainers/pigz:2.3.4' }"
diff --git a/modules/nf-core/cat/cat/meta.yml b/modules/nf-core/cat/cat/meta.yml
index 8acc0bfa..00a8db0b 100644
--- a/modules/nf-core/cat/cat/meta.yml
+++ b/modules/nf-core/cat/cat/meta.yml
@@ -7,9 +7,7 @@ keywords:
tools:
- cat:
description: Just concatenation
-
documentation: https://man7.org/linux/man-pages/man1/cat.1.html
-
licence: ["GPL-3.0-or-later"]
input:
- meta:
@@ -21,7 +19,6 @@ input:
type: file
description: List of compressed / uncompressed files
pattern: "*"
-
output:
- versions:
type: file
@@ -31,7 +28,9 @@ output:
type: file
description: Concatenated file. Will be gzipped if file_out ends with ".gz"
pattern: "${file_out}"
-
authors:
- "@erikrikarddaniel"
- "@FriederikeHanssen"
+maintainers:
+ - "@erikrikarddaniel"
+ - "@FriederikeHanssen"
diff --git a/modules/nf-core/cat/cat/tests/main.nf.test b/modules/nf-core/cat/cat/tests/main.nf.test
new file mode 100644
index 00000000..5766daaf
--- /dev/null
+++ b/modules/nf-core/cat/cat/tests/main.nf.test
@@ -0,0 +1,153 @@
+nextflow_process {
+
+ name "Test Process CAT_CAT"
+ script "../main.nf"
+ process "CAT_CAT"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "cat"
+ tag "cat/cat"
+
+ test("test_cat_unzipped_unzipped") {
+ when {
+ params {
+ outdir = "${outputDir}"
+ }
+ process {
+ """
+ input[0] =
+ [
+ [ id:'test', single_end:true ],
+ [
+ file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true),
+ file(params.test_data['sarscov2']['genome']['genome_sizes'], checkIfExists: true)
+ ]
+ ]
+ """
+ }
+ }
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out).match() }
+ )
+ }
+ }
+
+
+ test("test_cat_zipped_zipped") {
+ when {
+ params {
+ outdir = "${outputDir}"
+ }
+ process {
+ """
+ input[0] =
+ [
+ [ id:'test', single_end:true ],
+ [
+ file(params.test_data['sarscov2']['genome']['genome_gff3_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['genome']['contigs_genome_maf_gz'], checkIfExists: true)
+ ]
+ ]
+ """
+ }
+ }
+ then {
+ def lines = path(process.out.file_out.get(0).get(1)).linesGzip
+ assertAll(
+ { assert process.success },
+ { assert snapshot(lines[0..5]).match("test_cat_zipped_zipped_lines") },
+ { assert snapshot(lines.size()).match("test_cat_zipped_zipped_size")}
+ )
+ }
+ }
+
+ test("test_cat_zipped_unzipped") {
+ config './nextflow_zipped_unzipped.config'
+
+ when {
+ params {
+ outdir = "${outputDir}"
+ }
+ process {
+ """
+ input[0] =
+ [
+ [ id:'test', single_end:true ],
+ [
+ file(params.test_data['sarscov2']['genome']['genome_gff3_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['genome']['contigs_genome_maf_gz'], checkIfExists: true)
+ ]
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out).match() }
+ )
+ }
+
+ }
+
+ test("test_cat_unzipped_zipped") {
+ config './nextflow_unzipped_zipped.config'
+ when {
+ params {
+ outdir = "${outputDir}"
+ }
+ process {
+ """
+ input[0] =
+ [
+ [ id:'test', single_end:true ],
+ [
+ file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true),
+ file(params.test_data['sarscov2']['genome']['genome_sizes'], checkIfExists: true)
+ ]
+ ]
+ """
+ }
+ }
+ then {
+ def lines = path(process.out.file_out.get(0).get(1)).linesGzip
+ assertAll(
+ { assert process.success },
+ { assert snapshot(lines[0..5]).match("test_cat_unzipped_zipped_lines") },
+ { assert snapshot(lines.size()).match("test_cat_unzipped_zipped_size")}
+ )
+ }
+ }
+
+ test("test_cat_one_file_unzipped_zipped") {
+ config './nextflow_unzipped_zipped.config'
+ when {
+ params {
+ outdir = "${outputDir}"
+ }
+ process {
+ """
+ input[0] =
+ [
+ [ id:'test', single_end:true ],
+ [
+ file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
+ ]
+ ]
+ """
+ }
+ }
+ then {
+ def lines = path(process.out.file_out.get(0).get(1)).linesGzip
+ assertAll(
+ { assert process.success },
+ { assert snapshot(lines[0..5]).match("test_cat_one_file_unzipped_zipped_lines") },
+ { assert snapshot(lines.size()).match("test_cat_one_file_unzipped_zipped_size")}
+ )
+ }
+ }
+}
+
diff --git a/modules/nf-core/cat/cat/tests/main.nf.test.snap b/modules/nf-core/cat/cat/tests/main.nf.test.snap
new file mode 100644
index 00000000..423571ba
--- /dev/null
+++ b/modules/nf-core/cat/cat/tests/main.nf.test.snap
@@ -0,0 +1,121 @@
+{
+ "test_cat_unzipped_zipped_size": {
+ "content": [
+ 375
+ ],
+ "timestamp": "2023-10-16T14:33:08.049445686"
+ },
+ "test_cat_unzipped_unzipped": {
+ "content": [
+ {
+ "0": [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.fasta:md5,f44b33a0e441ad58b2d3700270e2dbe2"
+ ]
+ ],
+ "1": [
+ "versions.yml:md5,115ed6177ebcff24eb99d503fa5ef894"
+ ],
+ "file_out": [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.fasta:md5,f44b33a0e441ad58b2d3700270e2dbe2"
+ ]
+ ],
+ "versions": [
+ "versions.yml:md5,115ed6177ebcff24eb99d503fa5ef894"
+ ]
+ }
+ ],
+ "timestamp": "2023-10-16T14:32:18.500464399"
+ },
+ "test_cat_zipped_unzipped": {
+ "content": [
+ {
+ "0": [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "cat.txt:md5,c439d3b60e7bc03e8802a451a0d9a5d9"
+ ]
+ ],
+ "1": [
+ "versions.yml:md5,115ed6177ebcff24eb99d503fa5ef894"
+ ],
+ "file_out": [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "cat.txt:md5,c439d3b60e7bc03e8802a451a0d9a5d9"
+ ]
+ ],
+ "versions": [
+ "versions.yml:md5,115ed6177ebcff24eb99d503fa5ef894"
+ ]
+ }
+ ],
+ "timestamp": "2023-10-16T14:32:49.642741302"
+ },
+ "test_cat_zipped_zipped_lines": {
+ "content": [
+ [
+ "MT192765.1\tGenbank\ttranscript\t259\t29667\t.\t+\t.\tID=unknown_transcript_1;geneID=orf1ab;gene_name=orf1ab",
+ "MT192765.1\tGenbank\tgene\t259\t21548\t.\t+\t.\tParent=unknown_transcript_1",
+ "MT192765.1\tGenbank\tCDS\t259\t13461\t.\t+\t0\tParent=unknown_transcript_1;exception=\"ribosomal slippage\";gbkey=CDS;gene=orf1ab;note=\"pp1ab;translated=by -1 ribosomal frameshift\";product=\"orf1ab polyprotein\";protein_id=QIK50426.1",
+ "MT192765.1\tGenbank\tCDS\t13461\t21548\t.\t+\t0\tParent=unknown_transcript_1;exception=\"ribosomal slippage\";gbkey=CDS;gene=orf1ab;note=\"pp1ab;translated=by -1 ribosomal frameshift\";product=\"orf1ab polyprotein\";protein_id=QIK50426.1",
+ "MT192765.1\tGenbank\tCDS\t21556\t25377\t.\t+\t0\tParent=unknown_transcript_1;gbkey=CDS;gene=S;note=\"structural protein\";product=\"surface glycoprotein\";protein_id=QIK50427.1",
+ "MT192765.1\tGenbank\tgene\t21556\t25377\t.\t+\t.\tParent=unknown_transcript_1"
+ ]
+ ],
+ "timestamp": "2023-10-16T14:32:33.629048645"
+ },
+ "test_cat_unzipped_zipped_lines": {
+ "content": [
+ [
+ ">MT192765.1 Severe acute respiratory syndrome coronavirus 2 isolate SARS-CoV-2/human/USA/PC00101P/2020, complete genome",
+ "GTTTATACCTTCCCAGGTAACAAACCAACCAACTTTCGATCTCTTGTAGATCTGTTCTCTAAACGAACTTTAAAATCTGT",
+ "GTGGCTGTCACTCGGCTGCATGCTTAGTGCACTCACGCAGTATAATTAATAACTAATTACTGTCGTTGACAGGACACGAG",
+ "TAACTCGTCTATCTTCTGCAGGCTGCTTACGGTTTCGTCCGTGTTGCAGCCGATCATCAGCACATCTAGGTTTTGTCCGG",
+ "GTGTGACCGAAAGGTAAGATGGAGAGCCTTGTCCCTGGTTTCAACGAGAAAACACACGTCCAACTCAGTTTGCCTGTTTT",
+ "ACAGGTTCGCGACGTGCTCGTACGTGGCTTTGGAGACTCCGTGGAGGAGGTCTTATCAGAGGCACGTCAACATCTTAAAG"
+ ]
+ ],
+ "timestamp": "2023-10-16T14:33:08.038830506"
+ },
+ "test_cat_one_file_unzipped_zipped_lines": {
+ "content": [
+ [
+ ">MT192765.1 Severe acute respiratory syndrome coronavirus 2 isolate SARS-CoV-2/human/USA/PC00101P/2020, complete genome",
+ "GTTTATACCTTCCCAGGTAACAAACCAACCAACTTTCGATCTCTTGTAGATCTGTTCTCTAAACGAACTTTAAAATCTGT",
+ "GTGGCTGTCACTCGGCTGCATGCTTAGTGCACTCACGCAGTATAATTAATAACTAATTACTGTCGTTGACAGGACACGAG",
+ "TAACTCGTCTATCTTCTGCAGGCTGCTTACGGTTTCGTCCGTGTTGCAGCCGATCATCAGCACATCTAGGTTTTGTCCGG",
+ "GTGTGACCGAAAGGTAAGATGGAGAGCCTTGTCCCTGGTTTCAACGAGAAAACACACGTCCAACTCAGTTTGCCTGTTTT",
+ "ACAGGTTCGCGACGTGCTCGTACGTGGCTTTGGAGACTCCGTGGAGGAGGTCTTATCAGAGGCACGTCAACATCTTAAAG"
+ ]
+ ],
+ "timestamp": "2023-10-16T14:33:21.39642399"
+ },
+ "test_cat_zipped_zipped_size": {
+ "content": [
+ 78
+ ],
+ "timestamp": "2023-10-16T14:32:33.641869244"
+ },
+ "test_cat_one_file_unzipped_zipped_size": {
+ "content": [
+ 374
+ ],
+ "timestamp": "2023-10-16T14:33:21.4094373"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/cat/cat/tests/nextflow_unzipped_zipped.config b/modules/nf-core/cat/cat/tests/nextflow_unzipped_zipped.config
new file mode 100644
index 00000000..ec26b0fd
--- /dev/null
+++ b/modules/nf-core/cat/cat/tests/nextflow_unzipped_zipped.config
@@ -0,0 +1,6 @@
+
+process {
+ withName: CAT_CAT {
+ ext.prefix = 'cat.txt.gz'
+ }
+}
diff --git a/modules/nf-core/cat/cat/tests/nextflow_zipped_unzipped.config b/modules/nf-core/cat/cat/tests/nextflow_zipped_unzipped.config
new file mode 100644
index 00000000..fbc79783
--- /dev/null
+++ b/modules/nf-core/cat/cat/tests/nextflow_zipped_unzipped.config
@@ -0,0 +1,8 @@
+
+process {
+
+ withName: CAT_CAT {
+ ext.prefix = 'cat.txt'
+ }
+
+}
diff --git a/modules/nf-core/cat/cat/tests/tags.yml b/modules/nf-core/cat/cat/tests/tags.yml
new file mode 100644
index 00000000..37b578f5
--- /dev/null
+++ b/modules/nf-core/cat/cat/tests/tags.yml
@@ -0,0 +1,2 @@
+cat/cat:
+ - modules/nf-core/cat/cat/**
diff --git a/modules/nf-core/cat/fastq/environment.yml b/modules/nf-core/cat/fastq/environment.yml
new file mode 100644
index 00000000..bff93add
--- /dev/null
+++ b/modules/nf-core/cat/fastq/environment.yml
@@ -0,0 +1,7 @@
+name: cat_fastq
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - conda-forge::sed=4.7
diff --git a/modules/nf-core/cat/fastq/main.nf b/modules/nf-core/cat/fastq/main.nf
index 5021e6fc..3d963784 100644
--- a/modules/nf-core/cat/fastq/main.nf
+++ b/modules/nf-core/cat/fastq/main.nf
@@ -2,7 +2,7 @@ process CAT_FASTQ {
tag "$meta.id"
label 'process_single'
- conda "conda-forge::sed=4.7"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/ubuntu:20.04' :
'nf-core/ubuntu:20.04' }"
diff --git a/modules/nf-core/cat/fastq/meta.yml b/modules/nf-core/cat/fastq/meta.yml
index 8a39e309..db4ac3c7 100644
--- a/modules/nf-core/cat/fastq/meta.yml
+++ b/modules/nf-core/cat/fastq/meta.yml
@@ -34,7 +34,9 @@ output:
type: file
description: File containing software versions
pattern: "versions.yml"
-
authors:
- "@joseespinosa"
- "@drpatelh"
+maintainers:
+ - "@joseespinosa"
+ - "@drpatelh"
diff --git a/modules/nf-core/cat/fastq/tests/main.nf.test b/modules/nf-core/cat/fastq/tests/main.nf.test
new file mode 100644
index 00000000..f5f94182
--- /dev/null
+++ b/modules/nf-core/cat/fastq/tests/main.nf.test
@@ -0,0 +1,143 @@
+nextflow_process {
+
+ name "Test Process CAT_FASTQ"
+ script "../main.nf"
+ process "CAT_FASTQ"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "cat"
+ tag "cat/fastq"
+
+ test("test_cat_fastq_single_end") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test', single_end:true ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test2_1_fastq_gz'], checkIfExists: true) ]
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.reads).match() },
+ { assert path(process.out.versions.get(0)).getText().contains("cat") }
+ )
+ }
+ }
+
+ test("test_cat_fastq_paired_end") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test', single_end:false ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test2_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test2_2_fastq_gz'], checkIfExists: true) ]
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.reads).match() },
+ { assert path(process.out.versions.get(0)).getText().contains("cat") }
+ )
+ }
+ }
+
+ test("test_cat_fastq_single_end_same_name") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test', single_end:true ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true) ]
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.reads).match() },
+ { assert path(process.out.versions.get(0)).getText().contains("cat") }
+ )
+ }
+ }
+
+ test("test_cat_fastq_paired_end_same_name") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test', single_end:false ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true) ]
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.reads).match() },
+ { assert path(process.out.versions.get(0)).getText().contains("cat") }
+ )
+ }
+ }
+
+ test("test_cat_fastq_single_end_single_file") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test', single_end:true ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true)]
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.reads).match() },
+ { assert path(process.out.versions.get(0)).getText().contains("cat") }
+ )
+ }
+ }
+}
diff --git a/modules/nf-core/cat/fastq/tests/main.nf.test.snap b/modules/nf-core/cat/fastq/tests/main.nf.test.snap
new file mode 100644
index 00000000..ec2342e5
--- /dev/null
+++ b/modules/nf-core/cat/fastq/tests/main.nf.test.snap
@@ -0,0 +1,78 @@
+{
+ "test_cat_fastq_single_end": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.merged.fastq.gz:md5,f9cf5e375f7de81a406144a2c70cc64d"
+ ]
+ ]
+ ],
+ "timestamp": "2023-10-17T23:19:12.990284837"
+ },
+ "test_cat_fastq_single_end_same_name": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.merged.fastq.gz:md5,63f817db7a29a03eb538104495556f66"
+ ]
+ ]
+ ],
+ "timestamp": "2023-10-17T23:19:31.554568147"
+ },
+ "test_cat_fastq_single_end_single_file": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.merged.fastq.gz:md5,e325ef7deb4023447a1f074e285761af"
+ ]
+ ]
+ ],
+ "timestamp": "2023-10-17T23:19:49.629360033"
+ },
+ "test_cat_fastq_paired_end_same_name": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ [
+ "test_1.merged.fastq.gz:md5,63f817db7a29a03eb538104495556f66",
+ "test_2.merged.fastq.gz:md5,fe9f266f43a6fc3dcab690a18419a56e"
+ ]
+ ]
+ ]
+ ],
+ "timestamp": "2023-10-17T23:19:40.711617539"
+ },
+ "test_cat_fastq_paired_end": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ [
+ "test_1.merged.fastq.gz:md5,f9cf5e375f7de81a406144a2c70cc64d",
+ "test_2.merged.fastq.gz:md5,77c8e966e130d8c6b6ec9be52fcb2bda"
+ ]
+ ]
+ ]
+ ],
+ "timestamp": "2023-10-18T07:53:20.923560211"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/cat/fastq/tests/tags.yml b/modules/nf-core/cat/fastq/tests/tags.yml
new file mode 100644
index 00000000..6ac43614
--- /dev/null
+++ b/modules/nf-core/cat/fastq/tests/tags.yml
@@ -0,0 +1,2 @@
+cat/fastq:
+ - modules/nf-core/cat/fastq/**
diff --git a/modules/nf-core/custom/dumpsoftwareversions/environment.yml b/modules/nf-core/custom/dumpsoftwareversions/environment.yml
new file mode 100644
index 00000000..f0c63f69
--- /dev/null
+++ b/modules/nf-core/custom/dumpsoftwareversions/environment.yml
@@ -0,0 +1,7 @@
+name: custom_dumpsoftwareversions
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::multiqc=1.17
diff --git a/modules/nf-core/custom/dumpsoftwareversions/main.nf b/modules/nf-core/custom/dumpsoftwareversions/main.nf
index c9d014b1..7685b33c 100644
--- a/modules/nf-core/custom/dumpsoftwareversions/main.nf
+++ b/modules/nf-core/custom/dumpsoftwareversions/main.nf
@@ -2,10 +2,10 @@ process CUSTOM_DUMPSOFTWAREVERSIONS {
label 'process_single'
// Requires `pyyaml` which does not have a dedicated container but is in the MultiQC container
- conda "bioconda::multiqc=1.15"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/multiqc:1.15--pyhdfd78af_0' :
- 'biocontainers/multiqc:1.15--pyhdfd78af_0' }"
+ 'https://depot.galaxyproject.org/singularity/multiqc:1.17--pyhdfd78af_0' :
+ 'biocontainers/multiqc:1.17--pyhdfd78af_0' }"
input:
path versions
diff --git a/modules/nf-core/custom/dumpsoftwareversions/meta.yml b/modules/nf-core/custom/dumpsoftwareversions/meta.yml
index c32657de..5f15a5fd 100644
--- a/modules/nf-core/custom/dumpsoftwareversions/meta.yml
+++ b/modules/nf-core/custom/dumpsoftwareversions/meta.yml
@@ -1,4 +1,4 @@
-# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/yaml-schema.json
+# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/meta-schema.json
name: custom_dumpsoftwareversions
description: Custom module used to dump software versions within the nf-core pipeline template
keywords:
@@ -16,7 +16,6 @@ input:
type: file
description: YML file containing software versions
pattern: "*.yml"
-
output:
- yml:
type: file
@@ -30,7 +29,9 @@ output:
type: file
description: File containing software versions
pattern: "versions.yml"
-
authors:
- "@drpatelh"
- "@grst"
+maintainers:
+ - "@drpatelh"
+ - "@grst"
diff --git a/modules/nf-core/custom/dumpsoftwareversions/tests/main.nf.test b/modules/nf-core/custom/dumpsoftwareversions/tests/main.nf.test
new file mode 100644
index 00000000..eec1db10
--- /dev/null
+++ b/modules/nf-core/custom/dumpsoftwareversions/tests/main.nf.test
@@ -0,0 +1,38 @@
+nextflow_process {
+
+ name "Test Process CUSTOM_DUMPSOFTWAREVERSIONS"
+ script "../main.nf"
+ process "CUSTOM_DUMPSOFTWAREVERSIONS"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "custom"
+ tag "dumpsoftwareversions"
+ tag "custom/dumpsoftwareversions"
+
+ test("Should run without failures") {
+ when {
+ process {
+ """
+ def tool1_version = '''
+ TOOL1:
+ tool1: 0.11.9
+ '''.stripIndent()
+
+ def tool2_version = '''
+ TOOL2:
+ tool2: 1.9
+ '''.stripIndent()
+
+ input[0] = Channel.of(tool1_version, tool2_version).collectFile()
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out).match() }
+ )
+ }
+ }
+}
diff --git a/modules/nf-core/custom/dumpsoftwareversions/tests/main.nf.test.snap b/modules/nf-core/custom/dumpsoftwareversions/tests/main.nf.test.snap
new file mode 100644
index 00000000..4274ed57
--- /dev/null
+++ b/modules/nf-core/custom/dumpsoftwareversions/tests/main.nf.test.snap
@@ -0,0 +1,27 @@
+{
+ "Should run without failures": {
+ "content": [
+ {
+ "0": [
+ "software_versions.yml:md5,1c851188476409cda5752ce971b20b58"
+ ],
+ "1": [
+ "software_versions_mqc.yml:md5,2570f4ba271ad08357b0d3d32a9cf84d"
+ ],
+ "2": [
+ "versions.yml:md5,3843ac526e762117eedf8825b40683df"
+ ],
+ "mqc_yml": [
+ "software_versions_mqc.yml:md5,2570f4ba271ad08357b0d3d32a9cf84d"
+ ],
+ "versions": [
+ "versions.yml:md5,3843ac526e762117eedf8825b40683df"
+ ],
+ "yml": [
+ "software_versions.yml:md5,1c851188476409cda5752ce971b20b58"
+ ]
+ }
+ ],
+ "timestamp": "2023-11-03T14:43:22.157011"
+ }
+}
diff --git a/modules/nf-core/custom/dumpsoftwareversions/tests/tags.yml b/modules/nf-core/custom/dumpsoftwareversions/tests/tags.yml
new file mode 100644
index 00000000..405aa24a
--- /dev/null
+++ b/modules/nf-core/custom/dumpsoftwareversions/tests/tags.yml
@@ -0,0 +1,2 @@
+custom/dumpsoftwareversions:
+ - modules/nf-core/custom/dumpsoftwareversions/**
diff --git a/modules/nf-core/fastp/environment.yml b/modules/nf-core/fastp/environment.yml
new file mode 100644
index 00000000..70389e66
--- /dev/null
+++ b/modules/nf-core/fastp/environment.yml
@@ -0,0 +1,7 @@
+name: fastp
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::fastp=0.23.4
diff --git a/modules/nf-core/fastp/main.nf b/modules/nf-core/fastp/main.nf
index 831b7f12..c8e815ae 100644
--- a/modules/nf-core/fastp/main.nf
+++ b/modules/nf-core/fastp/main.nf
@@ -2,7 +2,7 @@ process FASTP {
tag "$meta.id"
label 'process_medium'
- conda "bioconda::fastp=0.23.4"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/fastp:0.23.4--h5f740d0_0' :
'biocontainers/fastp:0.23.4--h5f740d0_0' }"
diff --git a/modules/nf-core/fastp/meta.yml b/modules/nf-core/fastp/meta.yml
index 197ea7ca..c22a16ab 100644
--- a/modules/nf-core/fastp/meta.yml
+++ b/modules/nf-core/fastp/meta.yml
@@ -33,7 +33,6 @@ input:
- save_merged:
type: boolean
description: Specify true to save all merged reads to the a file ending in `*.merged.fastq.gz`
-
output:
- meta:
type: map
@@ -71,3 +70,6 @@ output:
authors:
- "@drpatelh"
- "@kevinmenden"
+maintainers:
+ - "@drpatelh"
+ - "@kevinmenden"
diff --git a/modules/nf-core/fastp/tests/main.nf.test b/modules/nf-core/fastp/tests/main.nf.test
new file mode 100644
index 00000000..f610b735
--- /dev/null
+++ b/modules/nf-core/fastp/tests/main.nf.test
@@ -0,0 +1,485 @@
+nextflow_process {
+
+ name "Test Process FASTP"
+ script "../main.nf"
+ process "FASTP"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "fastp"
+
+ test("test_fastp_single_end") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ adapter_fasta = []
+ save_trimmed_fail = false
+ save_merged = false
+
+ input[0] = [
+ [ id:'test', single_end:true ],
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true) ]
+ ]
+
+ input[1] = adapter_fasta
+ input[2] = save_trimmed_fail
+ input[3] = save_merged
+ """
+ }
+ }
+
+ then {
+ def html_text = [ "Q20 bases:12.922000 K (92.984097%)",
+ "single end (151 cycles)" ]
+ def log_text = [ "Q20 bases: 12922(92.9841%)",
+ "reads passed filter: 99" ]
+ def read_lines = ["@ERR5069949.2151832 NS500628:121:HK3MMAFX2:2:21208:10793:15304/1",
+ "TCATAAACCAAAGCACTCACAGTGTCAACAATTTCAGCAGGACAACGCCGACAAGTTCCGAGGAACATGTCTGGACCTATAGTTTTCATAAGTCTACACACTGAATTGAAATATTCTGGTTCTAGTGTGCCCTTAGTTAGCAATGTGCGT",
+ "AAAAAAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEE
+ { assert path(process.out.reads.get(0).get(1)).linesGzip.contains(read_line) }
+ }
+ },
+ { html_text.each { html_part ->
+ { assert path(process.out.html.get(0).get(1)).getText().contains(html_part) }
+ }
+ },
+ { assert snapshot(process.out.json).match("test_fastp_single_end_json") },
+ { log_text.each { log_part ->
+ { assert path(process.out.log.get(0).get(1)).getText().contains(log_part) }
+ }
+ },
+ { assert snapshot(process.out.versions).match("versions") }
+ )
+ }
+ }
+
+ test("test_fastp_paired_end") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ adapter_fasta = []
+ save_trimmed_fail = false
+ save_merged = false
+
+ input[0] = [
+ [ id:'test', single_end:false ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true) ]
+ ]
+
+ input[1] = adapter_fasta
+ input[2] = save_trimmed_fail
+ input[3] = save_merged
+ """
+ }
+ }
+
+ then {
+ def html_text = [ "Q20 bases: | 25.719000 K (93.033098%)",
+ "The input has little adapter percentage (~0.000000%), probably it's trimmed before."]
+ def log_text = [ "No adapter detected for read1",
+ "Q30 bases: 12281(88.3716%)"]
+ def json_text = ['"passed_filter_reads": 198']
+ def read1_lines = ["@ERR5069949.2151832 NS500628:121:HK3MMAFX2:2:21208:10793:15304/1",
+ "TCATAAACCAAAGCACTCACAGTGTCAACAATTTCAGCAGGACAACGCCGACAAGTTCCGAGGAACATGTCTGGACCTATAGTTTTCATAAGTCTACACACTGAATTGAAATATTCTGGTTCTAGTGTGCCCTTAGTTAGCAATGTGCGT",
+ "AAAAAAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEE
+ { assert path(process.out.reads.get(0).get(1).get(0)).linesGzip.contains(read1_line) }
+ }
+ },
+ { read2_lines.each { read2_line ->
+ { assert path(process.out.reads.get(0).get(1).get(1)).linesGzip.contains(read2_line) }
+ }
+ },
+ { html_text.each { html_part ->
+ { assert path(process.out.html.get(0).get(1)).getText().contains(html_part) }
+ }
+ },
+ { json_text.each { json_part ->
+ { assert path(process.out.json.get(0).get(1)).getText().contains(json_part) }
+ }
+ },
+ { log_text.each { log_part ->
+ { assert path(process.out.log.get(0).get(1)).getText().contains(log_part) }
+ }
+ },
+ { assert snapshot(process.out.versions).match("versions") }
+ )
+ }
+ }
+
+ test("fastp test_fastp_interleaved") {
+ config './nextflow.config'
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ adapter_fasta = []
+ save_trimmed_fail = false
+ save_merged = false
+
+ input[0] = [ [ id:'test', single_end:true ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_interleaved_fastq_gz'], checkIfExists: true) ]
+ ]
+
+ input[1] = adapter_fasta
+ input[2] = save_trimmed_fail
+ input[3] = save_merged
+ """
+ }
+ }
+
+ then {
+ def html_text = [ "Q20 bases: | 25.719000 K (93.033098%)",
+ "paired end (151 cycles + 151 cycles)"]
+ def log_text = [ "Q20 bases: 12922(92.9841%)",
+ "reads passed filter: 198"]
+ def read_lines = [ "@ERR5069949.2151832 NS500628:121:HK3MMAFX2:2:21208:10793:15304/1",
+ "TCATAAACCAAAGCACTCACAGTGTCAACAATTTCAGCAGGACAACGCCGACAAGTTCCGAGGAACATGTCTGGACCTATAGTTTTCATAAGTCTACACACTGAATTGAAATATTCTGGTTCTAGTGTGCCCTTAGTTAGCAATGTGCGT",
+ "AAAAAAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEE
+ { assert path(process.out.reads.get(0).get(1)).linesGzip.contains(read_line) }
+ }
+ },
+ { html_text.each { html_part ->
+ { assert path(process.out.html.get(0).get(1)).getText().contains(html_part) }
+ }
+ },
+ { assert snapshot(process.out.json).match("fastp test_fastp_interleaved_json") },
+ { log_text.each { log_part ->
+ { assert path(process.out.log.get(0).get(1)).getText().contains(log_part) }
+ }
+ },
+ { assert snapshot(process.out.versions).match("versions") }
+ )
+ }
+ }
+
+ test("test_fastp_single_end_trim_fail") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ adapter_fasta = []
+ save_trimmed_fail = true
+ save_merged = false
+
+ input[0] = [ [ id:'test', single_end:true ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true) ]
+ ]
+ input[1] = adapter_fasta
+ input[2] = save_trimmed_fail
+ input[3] = save_merged
+ """
+ }
+ }
+
+ then {
+ def html_text = [ "Q20 bases: | 12.922000 K (92.984097%)",
+ "single end (151 cycles)"]
+ def log_text = [ "Q20 bases: 12922(92.9841%)",
+ "reads passed filter: 99" ]
+ def read_lines = [ "@ERR5069949.2151832 NS500628:121:HK3MMAFX2:2:21208:10793:15304/1",
+ "TCATAAACCAAAGCACTCACAGTGTCAACAATTTCAGCAGGACAACGCCGACAAGTTCCGAGGAACATGTCTGGACCTATAGTTTTCATAAGTCTACACACTGAATTGAAATATTCTGGTTCTAGTGTGCCCTTAGTTAGCAATGTGCGT",
+ "AAAAAAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEE
+ { assert path(process.out.reads.get(0).get(1)).linesGzip.contains(read_line) }
+ }
+ },
+ { failed_read_lines.each { failed_read_line ->
+ { assert path(process.out.reads_fail.get(0).get(1)).linesGzip.contains(failed_read_line) }
+ }
+ },
+ { html_text.each { html_part ->
+ { assert path(process.out.html.get(0).get(1)).getText().contains(html_part) }
+ }
+ },
+ { assert snapshot(process.out.json).match("test_fastp_single_end_trim_fail_json") },
+ { log_text.each { log_part ->
+ { assert path(process.out.log.get(0).get(1)).getText().contains(log_part) }
+ }
+ },
+ { assert snapshot(process.out.versions).match("versions") }
+ )
+ }
+ }
+
+ test("test_fastp_paired_end_trim_fail") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ adapter_fasta = []
+ save_trimmed_fail = true
+ save_merged = false
+
+ input[0] = [
+ [ id:'test', single_end:false ], // meta map
+ [
+ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true)
+ ]
+ ]
+ input[1] = adapter_fasta
+ input[2] = save_trimmed_fail
+ input[3] = save_merged
+ """
+ }
+ }
+
+ then {
+ def html_text = [ "Q20 bases: | 25.719000 K (93.033098%)",
+ "The input has little adapter percentage (~0.000000%), probably it's trimmed before."]
+ def log_text = [ "No adapter detected for read1",
+ "Q30 bases: 12281(88.3716%)"]
+ def json_text = ['"passed_filter_reads": 198']
+ def read1_lines = ["@ERR5069949.2151832 NS500628:121:HK3MMAFX2:2:21208:10793:15304/1",
+ "TCATAAACCAAAGCACTCACAGTGTCAACAATTTCAGCAGGACAACGCCGACAAGTTCCGAGGAACATGTCTGGACCTATAGTTTTCATAAGTCTACACACTGAATTGAAATATTCTGGTTCTAGTGTGCCCTTAGTTAGCAATGTGCGT",
+ "AAAAAAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEAEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEAAEEEEE
+ { assert path(process.out.reads.get(0).get(1).get(0)).linesGzip.contains(read1_line) }
+ }
+ },
+ { read2_lines.each { read2_line ->
+ { assert path(process.out.reads.get(0).get(1).get(1)).linesGzip.contains(read2_line) }
+ }
+ },
+ { failed_read2_lines.each { failed_read2_line ->
+ { assert path(process.out.reads_fail.get(0).get(1).get(1)).linesGzip.contains(failed_read2_line) }
+ }
+ },
+ { html_text.each { html_part ->
+ { assert path(process.out.html.get(0).get(1)).getText().contains(html_part) }
+ }
+ },
+ { json_text.each { json_part ->
+ { assert path(process.out.json.get(0).get(1)).getText().contains(json_part) }
+ }
+ },
+ { log_text.each { log_part ->
+ { assert path(process.out.log.get(0).get(1)).getText().contains(log_part) }
+ }
+ },
+ { assert snapshot(process.out.versions).match("versions") }
+ )
+ }
+ }
+
+ test("test_fastp_paired_end_merged") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ adapter_fasta = []
+ save_trimmed_fail = false
+ save_merged = true
+
+ input[0] = [ [ id:'test', single_end:false ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true) ]
+ ]
+ input[1] = adapter_fasta
+ input[2] = save_trimmed_fail
+ input[3] = save_merged
+ """
+ }
+ }
+
+ then {
+ def html_text = [ ""]
+ def log_text = [ "Merged and filtered:",
+ "total reads: 75",
+ "total bases: 13683"]
+ def json_text = ['"merged_and_filtered": {', '"total_reads": 75', '"total_bases": 13683']
+ def read1_lines = [ "@ERR5069949.1066259 NS500628:121:HK3MMAFX2:1:11312:18369:8333/1",
+ "CCTTATGACAGCAAGAACTGTGTATGATGATGGTGCTAGGAGAGTGTGGACACTTATGAATGTCTTGACACTCGTTTATAAAGTTTATTATGGTAATGCTTTAGATCAAGCCATTTCCATGTGGGCTCTTATAATCTCTGTTACTTC",
+ "AAAAAEAEEAEEEEEEEEEEEEEEEEAEEEEAEEEEEEEEAEEEEEEEEEEEEEEEEE/EAEEEEEE/6EEEEEEEEEEAEEAEEE/EE/AEEAEEEEEAEEEA/EEAAEAE
+ { assert path(process.out.reads.get(0).get(1).get(0)).linesGzip.contains(read1_line) }
+ }
+ },
+ { read2_lines.each { read2_line ->
+ { assert path(process.out.reads.get(0).get(1).get(1)).linesGzip.contains(read2_line) }
+ }
+ },
+ { read_merged_lines.each { read_merged_line ->
+ { assert path(process.out.reads_merged.get(0).get(1)).linesGzip.contains(read_merged_line) }
+ }
+ },
+ { html_text.each { html_part ->
+ { assert path(process.out.html.get(0).get(1)).getText().contains(html_part) }
+ }
+ },
+ { json_text.each { json_part ->
+ { assert path(process.out.json.get(0).get(1)).getText().contains(json_part) }
+ }
+ },
+ { log_text.each { log_part ->
+ { assert path(process.out.log.get(0).get(1)).getText().contains(log_part) }
+ }
+ },
+ { assert snapshot(process.out.versions).match("versions") }
+ )
+ }
+ }
+
+ test("test_fastp_paired_end_merged_adapterlist") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ adapter_fasta = file("https://github.com/nf-core/test-datasets/raw/modules/data/delete_me/fastp/adapters.fasta", checkIfExists: true)
+ save_trimmed_fail = false
+ save_merged = true
+
+ input[0] = [ [ id:'test', single_end:false ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true) ]
+ ]
+ input[1] = adapter_fasta
+ input[2] = save_trimmed_fail
+ input[3] = save_merged
+ """
+ }
+ }
+
+ then {
+ def html_text = [ ""]
+ def log_text = [ "Merged and filtered:",
+ "total reads: 75",
+ "total bases: 13683"]
+ def json_text = ['"merged_and_filtered": {', '"total_reads": 75', '"total_bases": 13683',"--adapter_fasta"]
+ def read1_lines = ["@ERR5069949.1066259 NS500628:121:HK3MMAFX2:1:11312:18369:8333/1",
+ "CCTTATGACAGCAAGAACTGTGTATGATGATGGTGCTAGGAGAGTGTGGACACTTATGAATGTCTTGACACTCGTTTATAAAGTTTATTATGGTAATGCTTTAGATCAAGCCATTTCCATGTGGGCTCTTATAATCTCTGTTACTTC",
+ "AAAAAEAEEAEEEEEEEEEEEEEEEEAEEEEAEEEEEEEEAEEEEEEEEEEEEEEEEE/EAEEEEEE/6EEEEEEEEEEAEEAEEE/EE/AEEAEEEEEAEEEA/EEAAEAE
+ { assert path(process.out.reads.get(0).get(1).get(0)).linesGzip.contains(read1_line) }
+ }
+ },
+ { read2_lines.each { read2_line ->
+ { assert path(process.out.reads.get(0).get(1).get(1)).linesGzip.contains(read2_line) }
+ }
+ },
+ { read_merged_lines.each { read_merged_line ->
+ { assert path(process.out.reads_merged.get(0).get(1)).linesGzip.contains(read_merged_line) }
+ }
+ },
+ { html_text.each { html_part ->
+ { assert path(process.out.html.get(0).get(1)).getText().contains(html_part) }
+ }
+ },
+ { json_text.each { json_part ->
+ { assert path(process.out.json.get(0).get(1)).getText().contains(json_part) }
+ }
+ },
+ { log_text.each { log_part ->
+ { assert path(process.out.log.get(0).get(1)).getText().contains(log_part) }
+ }
+ },
+ { assert snapshot(process.out.versions).match("versions") }
+ )
+ }
+ }
+}
diff --git a/modules/nf-core/fastp/tests/main.nf.test.snap b/modules/nf-core/fastp/tests/main.nf.test.snap
new file mode 100644
index 00000000..0fa68c7d
--- /dev/null
+++ b/modules/nf-core/fastp/tests/main.nf.test.snap
@@ -0,0 +1,52 @@
+{
+ "fastp test_fastp_interleaved_json": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.fastp.json:md5,168f516f7bd4b7b6c32da7cba87299a4"
+ ]
+ ]
+ ],
+ "timestamp": "2023-10-17T11:04:45.794175881"
+ },
+ "test_fastp_single_end_json": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.fastp.json:md5,c852d7a6dba5819e4ac8d9673bedcacc"
+ ]
+ ]
+ ],
+ "timestamp": "2023-10-17T11:04:10.566343705"
+ },
+ "versions": {
+ "content": [
+ [
+ "versions.yml:md5,48ffc994212fb1fc9f83a74fa69c9f02"
+ ]
+ ],
+ "timestamp": "2023-10-17T11:04:10.582076024"
+ },
+ "test_fastp_single_end_trim_fail_json": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.fastp.json:md5,9a7ee180f000e8d00c7fb67f06293eb5"
+ ]
+ ]
+ ],
+ "timestamp": "2023-10-17T11:05:00.379878948"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/fastp/tests/nextflow.config b/modules/nf-core/fastp/tests/nextflow.config
new file mode 100644
index 00000000..0f7849ad
--- /dev/null
+++ b/modules/nf-core/fastp/tests/nextflow.config
@@ -0,0 +1,6 @@
+process {
+
+ withName: FASTP {
+ ext.args = "--interleaved_in"
+ }
+}
diff --git a/modules/nf-core/fastp/tests/tags.yml b/modules/nf-core/fastp/tests/tags.yml
new file mode 100644
index 00000000..c1afcce7
--- /dev/null
+++ b/modules/nf-core/fastp/tests/tags.yml
@@ -0,0 +1,2 @@
+fastp:
+ - modules/nf-core/fastp/**
diff --git a/modules/nf-core/fastqc/environment.yml b/modules/nf-core/fastqc/environment.yml
new file mode 100644
index 00000000..1787b38a
--- /dev/null
+++ b/modules/nf-core/fastqc/environment.yml
@@ -0,0 +1,7 @@
+name: fastqc
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::fastqc=0.12.1
diff --git a/modules/nf-core/fastqc/main.nf b/modules/nf-core/fastqc/main.nf
index 249f9064..50e59f2b 100644
--- a/modules/nf-core/fastqc/main.nf
+++ b/modules/nf-core/fastqc/main.nf
@@ -2,10 +2,10 @@ process FASTQC {
tag "$meta.id"
label 'process_medium'
- conda "bioconda::fastqc=0.11.9"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/fastqc:0.11.9--0' :
- 'biocontainers/fastqc:0.11.9--0' }"
+ 'https://depot.galaxyproject.org/singularity/fastqc:0.12.1--hdfd78af_0' :
+ 'biocontainers/fastqc:0.12.1--hdfd78af_0' }"
input:
tuple val(meta), path(reads)
diff --git a/modules/nf-core/fastqc/meta.yml b/modules/nf-core/fastqc/meta.yml
index 4da5bb5a..ee5507e0 100644
--- a/modules/nf-core/fastqc/meta.yml
+++ b/modules/nf-core/fastqc/meta.yml
@@ -50,3 +50,8 @@ authors:
- "@grst"
- "@ewels"
- "@FelixKrueger"
+maintainers:
+ - "@drpatelh"
+ - "@grst"
+ - "@ewels"
+ - "@FelixKrueger"
diff --git a/modules/nf-core/fastqc/tests/main.nf.test b/modules/nf-core/fastqc/tests/main.nf.test
index 3961de60..6437a144 100644
--- a/modules/nf-core/fastqc/tests/main.nf.test
+++ b/modules/nf-core/fastqc/tests/main.nf.test
@@ -1,13 +1,18 @@
nextflow_process {
name "Test Process FASTQC"
- script "modules/nf-core/fastqc/main.nf"
+ script "../main.nf"
process "FASTQC"
+ tag "modules"
+ tag "modules_nfcore"
tag "fastqc"
test("Single-Read") {
when {
+ params {
+ outdir = "$outputDir"
+ }
process {
"""
input[0] = [
@@ -21,12 +26,16 @@ nextflow_process {
}
then {
- assert process.success
- assert process.out.html.get(0).get(1) ==~ ".*/test_fastqc.html"
- assert path(process.out.html.get(0).get(1)).getText().contains("File type | Conventional base calls | ")
- assert process.out.zip.get(0).get(1) ==~ ".*/test_fastqc.zip"
+ assertAll (
+ { assert process.success },
+ // NOTE The report contains the date inside it, which means that the md5sum is stable per day, but not longer than that. So you can't md5sum it.
+ // looks like this:
+ // https://github.com/nf-core/modules/pull/3903#issuecomment-1743620039
+ { assert process.out.html.get(0).get(1) ==~ ".*/test_fastqc.html" },
+ { assert path(process.out.html.get(0).get(1)).getText().contains("File type | Conventional base calls | ") },
+ { assert snapshot(process.out.versions).match("versions") },
+ { assert process.out.zip.get(0).get(1) ==~ ".*/test_fastqc.zip" }
+ )
}
-
}
-
}
diff --git a/modules/nf-core/fastqc/tests/main.nf.test.snap b/modules/nf-core/fastqc/tests/main.nf.test.snap
new file mode 100644
index 00000000..636a32ce
--- /dev/null
+++ b/modules/nf-core/fastqc/tests/main.nf.test.snap
@@ -0,0 +1,10 @@
+{
+ "versions": {
+ "content": [
+ [
+ "versions.yml:md5,e1cc25ca8af856014824abd842e93978"
+ ]
+ ],
+ "timestamp": "2023-10-09T23:40:54+0000"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/fastqc/tests/tags.yml b/modules/nf-core/fastqc/tests/tags.yml
new file mode 100644
index 00000000..7834294b
--- /dev/null
+++ b/modules/nf-core/fastqc/tests/tags.yml
@@ -0,0 +1,2 @@
+fastqc:
+ - modules/nf-core/fastqc/**
diff --git a/modules/nf-core/gatk4/bedtointervallist/environment.yml b/modules/nf-core/gatk4/bedtointervallist/environment.yml
new file mode 100644
index 00000000..e7cb4280
--- /dev/null
+++ b/modules/nf-core/gatk4/bedtointervallist/environment.yml
@@ -0,0 +1,7 @@
+name: gatk4_bedtointervallist
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::gatk4=4.4.0.0
diff --git a/modules/nf-core/gatk4/bedtointervallist/main.nf b/modules/nf-core/gatk4/bedtointervallist/main.nf
index a23abd06..88b24b1a 100644
--- a/modules/nf-core/gatk4/bedtointervallist/main.nf
+++ b/modules/nf-core/gatk4/bedtointervallist/main.nf
@@ -2,7 +2,7 @@ process GATK4_BEDTOINTERVALLIST {
tag "$meta.id"
label 'process_medium'
- conda "bioconda::gatk4=4.4.0.0"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/gatk4:4.4.0.0--py36hdfd78af_0':
'biocontainers/gatk4:4.4.0.0--py36hdfd78af_0' }"
@@ -29,7 +29,8 @@ process GATK4_BEDTOINTERVALLIST {
avail_mem = (task.memory.mega*0.8).intValue()
}
"""
- gatk --java-options "-Xmx${avail_mem}M" BedToIntervalList \\
+ gatk --java-options "-Xmx${avail_mem}M -XX:-UsePerfData" \\
+ BedToIntervalList \\
--INPUT $bed \\
--OUTPUT ${prefix}.interval_list \\
--SEQUENCE_DICTIONARY $dict \\
diff --git a/modules/nf-core/gatk4/bedtointervallist/meta.yml b/modules/nf-core/gatk4/bedtointervallist/meta.yml
index 40daf752..187da885 100644
--- a/modules/nf-core/gatk4/bedtointervallist/meta.yml
+++ b/modules/nf-core/gatk4/bedtointervallist/meta.yml
@@ -2,8 +2,9 @@ name: gatk4_bedtointervallist
description: Creates an interval list from a bed file and a reference dict
keywords:
- bed
- - interval list
- bedtointervallist
+ - gatk4
+ - interval list
tools:
- gatk4:
description: |
@@ -45,3 +46,6 @@ output:
authors:
- "@kevinmenden"
- "@ramprasadn"
+maintainers:
+ - "@kevinmenden"
+ - "@ramprasadn"
diff --git a/modules/nf-core/gatk4/createsequencedictionary/environment.yml b/modules/nf-core/gatk4/createsequencedictionary/environment.yml
new file mode 100644
index 00000000..db663e14
--- /dev/null
+++ b/modules/nf-core/gatk4/createsequencedictionary/environment.yml
@@ -0,0 +1,7 @@
+name: gatk4_createsequencedictionary
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::gatk4=4.4.0.0
diff --git a/modules/nf-core/gatk4/createsequencedictionary/main.nf b/modules/nf-core/gatk4/createsequencedictionary/main.nf
index 15a86bea..b47ad162 100644
--- a/modules/nf-core/gatk4/createsequencedictionary/main.nf
+++ b/modules/nf-core/gatk4/createsequencedictionary/main.nf
@@ -2,7 +2,7 @@ process GATK4_CREATESEQUENCEDICTIONARY {
tag "$fasta"
label 'process_medium'
- conda "bioconda::gatk4=4.4.0.0"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/gatk4:4.4.0.0--py36hdfd78af_0':
'biocontainers/gatk4:4.4.0.0--py36hdfd78af_0' }"
@@ -27,7 +27,8 @@ process GATK4_CREATESEQUENCEDICTIONARY {
avail_mem = (task.memory.mega*0.8).intValue()
}
"""
- gatk --java-options "-Xmx${avail_mem}M" CreateSequenceDictionary \\
+ gatk --java-options "-Xmx${avail_mem}M -XX:-UsePerfData" \\
+ CreateSequenceDictionary \\
--REFERENCE $fasta \\
--URI $fasta \\
--TMP_DIR . \\
diff --git a/modules/nf-core/gatk4/createsequencedictionary/meta.yml b/modules/nf-core/gatk4/createsequencedictionary/meta.yml
index a421e681..f9d70be0 100644
--- a/modules/nf-core/gatk4/createsequencedictionary/meta.yml
+++ b/modules/nf-core/gatk4/createsequencedictionary/meta.yml
@@ -1,9 +1,10 @@
name: gatk4_createsequencedictionary
description: Creates a sequence dictionary for a reference sequence
keywords:
+ - createsequencedictionary
- dictionary
- fasta
- - createsequencedictionary
+ - gatk4
tools:
- gatk:
description: |
@@ -14,7 +15,6 @@ tools:
documentation: https://gatk.broadinstitute.org/hc/en-us/categories/360002369672s
doi: 10.1158/1538-7445.AM2017-3590
licence: ["Apache-2.0"]
-
input:
- meta:
type: map
@@ -37,3 +37,6 @@ output:
authors:
- "@maxulysse"
- "@ramprasadn"
+maintainers:
+ - "@maxulysse"
+ - "@ramprasadn"
diff --git a/modules/nf-core/gatk4/markduplicates/environment.yml b/modules/nf-core/gatk4/markduplicates/environment.yml
new file mode 100644
index 00000000..9adad104
--- /dev/null
+++ b/modules/nf-core/gatk4/markduplicates/environment.yml
@@ -0,0 +1,8 @@
+name: gatk4_markduplicates
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::gatk4=4.4.0.0
+ - bioconda::samtools=1.17
diff --git a/modules/nf-core/gatk4/markduplicates/main.nf b/modules/nf-core/gatk4/markduplicates/main.nf
new file mode 100644
index 00000000..564b86d3
--- /dev/null
+++ b/modules/nf-core/gatk4/markduplicates/main.nf
@@ -0,0 +1,85 @@
+process GATK4_MARKDUPLICATES {
+ tag "$meta.id"
+ label 'process_medium'
+
+ conda "${moduleDir}/environment.yml"
+ container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
+ 'https://depot.galaxyproject.org/singularity/mulled-v2-d9e7bad0f7fbc8f4458d5c3ab7ffaaf0235b59fb:f857e2d6cc88d35580d01cf39e0959a68b83c1d9-0':
+ 'biocontainers/mulled-v2-d9e7bad0f7fbc8f4458d5c3ab7ffaaf0235b59fb:f857e2d6cc88d35580d01cf39e0959a68b83c1d9-0' }"
+
+ input:
+ tuple val(meta), path(bam)
+ path fasta
+ path fasta_fai
+
+ output:
+ tuple val(meta), path("*cram"), emit: cram, optional: true
+ tuple val(meta), path("*bam"), emit: bam, optional: true
+ tuple val(meta), path("*.crai"), emit: crai, optional: true
+ tuple val(meta), path("*.bai"), emit: bai, optional: true
+ tuple val(meta), path("*.metrics"), emit: metrics
+ path "versions.yml", emit: versions
+
+ when:
+ task.ext.when == null || task.ext.when
+
+ script:
+ def args = task.ext.args ?: ''
+ prefix = task.ext.prefix ?: "${meta.id}.bam"
+
+ // If the extension is CRAM, then change it to BAM
+ prefix_bam = prefix.tokenize('.')[-1] == 'cram' ? "${prefix.substring(0, prefix.lastIndexOf('.'))}.bam" : prefix
+
+ def input_list = bam.collect{"--INPUT $it"}.join(' ')
+ def reference = fasta ? "--REFERENCE_SEQUENCE ${fasta}" : ""
+
+ def avail_mem = 3072
+ if (!task.memory) {
+ log.info '[GATK MarkDuplicates] Available memory not known - defaulting to 3GB. Specify process memory requirements to change this.'
+ } else {
+ avail_mem = (task.memory.mega*0.8).intValue()
+ }
+
+ // Using samtools and not Markduplicates to compress to CRAM speeds up computation:
+ // https://medium.com/@acarroll.dna/looking-at-trade-offs-in-compression-levels-for-genomics-tools-eec2834e8b94
+ """
+ gatk --java-options "-Xmx${avail_mem}M -XX:-UsePerfData" \\
+ MarkDuplicates \\
+ $input_list \\
+ --OUTPUT ${prefix_bam} \\
+ --METRICS_FILE ${prefix}.metrics \\
+ --TMP_DIR . \\
+ ${reference} \\
+ $args
+
+ # If cram files are wished as output, the run samtools for conversion
+ if [[ ${prefix} == *.cram ]]; then
+ samtools view -Ch -T ${fasta} -o ${prefix} ${prefix_bam}
+ rm ${prefix_bam}
+ samtools index ${prefix}
+ fi
+
+ cat <<-END_VERSIONS > versions.yml
+ "${task.process}":
+ gatk4: \$(echo \$(gatk --version 2>&1) | sed 's/^.*(GATK) v//; s/ .*\$//')
+ samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//')
+ END_VERSIONS
+ """
+
+ stub:
+ prefix = task.ext.prefix ?: "${meta.id}.bam"
+ prefix_no_suffix = task.ext.prefix ? prefix.tokenize('.')[0] : "${meta.id}"
+ """
+ touch ${prefix_no_suffix}.bam
+ touch ${prefix_no_suffix}.cram
+ touch ${prefix_no_suffix}.cram.crai
+ touch ${prefix_no_suffix}.bai
+ touch ${prefix}.metrics
+
+ cat <<-END_VERSIONS > versions.yml
+ "${task.process}":
+ gatk4: \$(echo \$(gatk --version 2>&1) | sed 's/^.*(GATK) v//; s/ .*\$//')
+ samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//')
+ END_VERSIONS
+ """
+}
diff --git a/modules/nf-core/gatk4/markduplicates/meta.yml b/modules/nf-core/gatk4/markduplicates/meta.yml
new file mode 100644
index 00000000..b0f09d4b
--- /dev/null
+++ b/modules/nf-core/gatk4/markduplicates/meta.yml
@@ -0,0 +1,71 @@
+name: gatk4_markduplicates
+description: This tool locates and tags duplicate reads in a BAM or SAM file, where duplicate reads are defined as originating from a single fragment of DNA.
+keywords:
+ - bam
+ - gatk4
+ - markduplicates
+ - sort
+tools:
+ - gatk4:
+ description: Developed in the Data Sciences Platform at the Broad Institute, the toolkit offers a wide variety of tools with a primary focus on variant discovery and genotyping. Its powerful processing engine and high-performance computing features make it capable of taking on projects of any size.
+ homepage: https://gatk.broadinstitute.org/hc/en-us
+ documentation: https://gatk.broadinstitute.org/hc/en-us/articles/360037052812-MarkDuplicates-Picard-
+ tool_dev_url: https://github.com/broadinstitute/gatk
+ doi: 10.1158/1538-7445.AM2017-3590
+ licence: ["MIT"]
+input:
+ - meta:
+ type: map
+ description: |
+ Groovy Map containing sample information
+ e.g. [ id:'test', single_end:false ]
+ - bam:
+ type: file
+ description: Sorted BAM file
+ pattern: "*.{bam}"
+ - fasta:
+ type: file
+ description: Fasta file
+ pattern: "*.{fasta}"
+ - fasta_fai:
+ type: file
+ description: Fasta index file
+ pattern: "*.{fai}"
+output:
+ - meta:
+ type: map
+ description: |
+ Groovy Map containing sample information
+ e.g. [ id:'test', single_end:false ]
+ - versions:
+ type: file
+ description: File containing software versions
+ pattern: "versions.yml"
+ - bam:
+ type: file
+ description: Marked duplicates BAM file
+ pattern: "*.{bam}"
+ - cram:
+ type: file
+ description: Marked duplicates CRAM file
+ pattern: "*.{cram}"
+ - bai:
+ type: file
+ description: BAM index file
+ pattern: "*.{bam.bai}"
+ - crai:
+ type: file
+ description: CRAM index file
+ pattern: "*.{cram.crai}"
+ - metrics:
+ type: file
+ description: Duplicate metrics file generated by GATK
+ pattern: "*.{metrics.txt}"
+authors:
+ - "@ajodeh-juma"
+ - "@FriederikeHanssen"
+ - "@maxulysse"
+maintainers:
+ - "@ajodeh-juma"
+ - "@FriederikeHanssen"
+ - "@maxulysse"
diff --git a/modules/nf-core/kallisto/index/main.nf b/modules/nf-core/kallisto/index/main.nf
deleted file mode 100644
index fb9e44d9..00000000
--- a/modules/nf-core/kallisto/index/main.nf
+++ /dev/null
@@ -1,44 +0,0 @@
-process KALLISTO_INDEX {
- tag "$fasta"
- label 'process_medium'
-
- conda "bioconda::kallisto=0.46.2"
- container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/kallisto:0.46.2--h4f7b962_1' :
- 'biocontainers/kallisto:0.46.2--h4f7b962_1' }"
-
- input:
- tuple val(meta), path(fasta)
-
- output:
- tuple val(meta), path("kallisto") , emit: index
- path "versions.yml" , emit: versions
-
- when:
- task.ext.when == null || task.ext.when
-
- script:
- def args = task.ext.args ?: ''
- """
- kallisto \\
- index \\
- $args \\
- -i kallisto \\
- $fasta
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- kallisto: \$(echo \$(kallisto 2>&1) | sed 's/^kallisto //; s/Usage.*\$//')
- END_VERSIONS
- """
-
- stub:
- """
- touch kallisto
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- kallisto: \$(echo \$(kallisto 2>&1) | sed 's/^kallisto //; s/Usage.*\$//')
- END_VERSIONS
- """
-}
diff --git a/modules/nf-core/kallisto/index/meta.yml b/modules/nf-core/kallisto/index/meta.yml
deleted file mode 100644
index 05dfa53d..00000000
--- a/modules/nf-core/kallisto/index/meta.yml
+++ /dev/null
@@ -1,43 +0,0 @@
-name: kallisto_index
-description: Create kallisto index
-keywords:
- - kallisto
- - kallisto/index
- - index
-tools:
- - kallisto:
- description: Quantifying abundances of transcripts from bulk and single-cell RNA-Seq data, or more generally of target sequences using high-throughput sequencing reads.
- homepage: https://pachterlab.github.io/kallisto/
- documentation: https://pachterlab.github.io/kallisto/manual
- tool_dev_url: https://github.com/pachterlab/kallisto
-
- licence: ["BSD-2-Clause"]
-
-input:
- - meta:
- type: map
- description: |
- Groovy Map containing reference information
- e.g. [ id:'test' ]
- - fasta:
- type: file
- description: genome fasta file
- pattern: "*.{fasta}"
-
-output:
- - meta:
- type: map
- description: |
- Groovy Map containing reference information
- e.g. [ id:'test' ]
- - index:
- type: directory
- description: Kallisto genome index
- pattern: "*.idx"
- - versions:
- type: file
- description: File containing software versions
- pattern: "versions.yml"
-
-authors:
- - "@ggabernet"
diff --git a/modules/nf-core/multiqc/environment.yml b/modules/nf-core/multiqc/environment.yml
new file mode 100644
index 00000000..bc0bdb5b
--- /dev/null
+++ b/modules/nf-core/multiqc/environment.yml
@@ -0,0 +1,7 @@
+name: multiqc
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::multiqc=1.18
diff --git a/modules/nf-core/multiqc/main.nf b/modules/nf-core/multiqc/main.nf
index 65d7dd0d..00cc48d2 100644
--- a/modules/nf-core/multiqc/main.nf
+++ b/modules/nf-core/multiqc/main.nf
@@ -1,10 +1,10 @@
process MULTIQC {
label 'process_single'
- conda "bioconda::multiqc=1.15"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/multiqc:1.15--pyhdfd78af_0' :
- 'biocontainers/multiqc:1.15--pyhdfd78af_0' }"
+ 'https://depot.galaxyproject.org/singularity/multiqc:1.18--pyhdfd78af_0' :
+ 'biocontainers/multiqc:1.18--pyhdfd78af_0' }"
input:
path multiqc_files, stageAs: "?/*"
@@ -25,12 +25,14 @@ process MULTIQC {
def args = task.ext.args ?: ''
def config = multiqc_config ? "--config $multiqc_config" : ''
def extra_config = extra_multiqc_config ? "--config $extra_multiqc_config" : ''
+ def logo = multiqc_logo ? /--cl-config 'custom_logo: "${multiqc_logo}"'/ : ''
"""
multiqc \\
--force \\
$args \\
$config \\
$extra_config \\
+ $logo \\
.
cat <<-END_VERSIONS > versions.yml
diff --git a/modules/nf-core/multiqc/meta.yml b/modules/nf-core/multiqc/meta.yml
index f93b5ee5..f1aa660e 100644
--- a/modules/nf-core/multiqc/meta.yml
+++ b/modules/nf-core/multiqc/meta.yml
@@ -1,5 +1,5 @@
-# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/yaml-schema.json
-name: MultiQC
+# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/meta-schema.json
+name: multiqc
description: Aggregate results from bioinformatics analyses across many samples into a single report
keywords:
- QC
@@ -13,7 +13,6 @@ tools:
homepage: https://multiqc.info/
documentation: https://multiqc.info/docs/
licence: ["GPL-3.0-or-later"]
-
input:
- multiqc_files:
type: file
@@ -31,7 +30,6 @@ input:
type: file
description: Optional logo file for MultiQC
pattern: "*.{png}"
-
output:
- report:
type: file
@@ -54,3 +52,8 @@ authors:
- "@bunop"
- "@drpatelh"
- "@jfy133"
+maintainers:
+ - "@abhi18av"
+ - "@bunop"
+ - "@drpatelh"
+ - "@jfy133"
diff --git a/modules/nf-core/multiqc/tests/main.nf.test b/modules/nf-core/multiqc/tests/main.nf.test
new file mode 100644
index 00000000..68fffa90
--- /dev/null
+++ b/modules/nf-core/multiqc/tests/main.nf.test
@@ -0,0 +1,91 @@
+nextflow_process {
+
+ name "Test Process MULTIQC"
+ script "../main.nf"
+ process "MULTIQC"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "multiqc"
+
+ test("MULTIQC: FASTQC") {
+
+ setup {
+ run("FASTQC") {
+ script "../../fastqc/main.nf"
+ process {
+ """
+ input[0] = Channel.of([
+ [ id: 'test', single_end: false ],
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true)]
+ ])
+ """
+ }
+ }
+ }
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = FASTQC.out.zip.collect { it[1] }
+ input[1] = []
+ input[2] = []
+ input[3] = []
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert path(process.out.report.get(0)).exists() },
+ { assert path(process.out.data.get(0)).exists() },
+ { assert path(process.out.versions.get(0)).getText().contains("multiqc") }
+ )
+ }
+
+ }
+
+ test("MULTIQC: FASTQC and a config file") {
+
+ setup {
+ run("FASTQC") {
+ script "../../fastqc/main.nf"
+ process {
+ """
+ input[0] = Channel.of([
+ [ id: 'test', single_end: false ],
+ [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true)]
+ ])
+ """
+ }
+ }
+ }
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = FASTQC.out.zip.collect { it[1] }
+ input[1] = Channel.of(file("https://github.com/nf-core/tools/raw/dev/nf_core/pipeline-template/assets/multiqc_config.yml", checkIfExists: true))
+ input[2] = []
+ input[3] = []
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert path(process.out.report.get(0)).exists() },
+ { assert path(process.out.data.get(0)).exists() },
+ { assert path(process.out.versions.get(0)).getText().contains("multiqc") }
+ )
+ }
+
+ }
+}
diff --git a/modules/nf-core/multiqc/tests/tags.yml b/modules/nf-core/multiqc/tests/tags.yml
new file mode 100644
index 00000000..bea6c0d3
--- /dev/null
+++ b/modules/nf-core/multiqc/tests/tags.yml
@@ -0,0 +1,2 @@
+multiqc:
+ - modules/nf-core/multiqc/**
diff --git a/modules/nf-core/picard/collectinsertsizemetrics/environment.yml b/modules/nf-core/picard/collectinsertsizemetrics/environment.yml
new file mode 100644
index 00000000..5c85f872
--- /dev/null
+++ b/modules/nf-core/picard/collectinsertsizemetrics/environment.yml
@@ -0,0 +1,7 @@
+name: picard_collectinsertsizemetrics
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::picard=3.1.0
diff --git a/modules/nf-core/picard/collectinsertsizemetrics/main.nf b/modules/nf-core/picard/collectinsertsizemetrics/main.nf
new file mode 100644
index 00000000..48e4d2ad
--- /dev/null
+++ b/modules/nf-core/picard/collectinsertsizemetrics/main.nf
@@ -0,0 +1,61 @@
+process PICARD_COLLECTINSERTSIZEMETRICS {
+ tag "$meta.id"
+ label 'process_single'
+
+ conda "${moduleDir}/environment.yml"
+ container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
+ 'https://depot.galaxyproject.org/singularity/picard:3.1.0--hdfd78af_0' :
+ 'biocontainers/picard:3.1.0--hdfd78af_0' }"
+
+ input:
+ tuple val(meta), path(bam)
+
+ output:
+ tuple val(meta), path("*.txt"), emit: metrics
+ tuple val(meta), path("*.pdf"), emit: histogram
+ path "versions.yml" , emit: versions
+
+ when:
+ task.ext.when == null || task.ext.when
+
+ script:
+ def args = task.ext.args ?: ''
+ def prefix = task.ext.prefix ?: "${meta.id}"
+
+ def avail_mem = 3072
+ if (!task.memory) {
+ log.info '[Picard CollectInsertSizeMetrics] Available memory not known - defaulting to 3GB. Specify process memory requirements to change this.'
+ } else {
+ avail_mem = (task.memory.mega*0.8).intValue()
+ }
+ """
+ picard \\
+ -Xmx${avail_mem}M \\
+ CollectInsertSizeMetrics \\
+ $args \\
+ --INPUT $bam \\
+ --OUTPUT ${prefix}.txt \\
+ --Histogram_FILE ${prefix}.pdf \\
+ $args
+
+ cat <<-END_VERSIONS > versions.yml
+ "${task.process}":
+ picard: \$(picard CollectInsertSizeMetrics --version 2>&1 | grep -o 'Version:.*' | cut -f2- -d:)
+ END_VERSIONS
+ """
+
+
+ stub:
+ def prefix = task.ext.prefix ?: "${meta.id}"
+ """
+ touch ${prefix}.pdf
+ touch ${prefix}.txt
+ cat <<-END_VERSIONS > versions.yml
+ "${task.process}":
+ picard: \$(picard CollectInsertSizeMetrics --version 2>&1 | grep -o 'Version:.*' | cut -f2- -d:)
+ END_VERSIONS
+ """
+
+
+
+}
diff --git a/modules/nf-core/picard/collectinsertsizemetrics/meta.yml b/modules/nf-core/picard/collectinsertsizemetrics/meta.yml
new file mode 100644
index 00000000..efd5abe0
--- /dev/null
+++ b/modules/nf-core/picard/collectinsertsizemetrics/meta.yml
@@ -0,0 +1,47 @@
+name: "picard_collectinsertsizemetrics"
+description: Collect metrics about the insert size distribution of a paired-end library.
+keywords:
+ - metrics
+ - alignment
+ - insert
+ - statistics
+ - bam
+tools:
+ - "picard":
+ description: "Java tools for working with NGS data in the BAM format"
+ homepage: "https://broadinstitute.github.io/picard/"
+ documentation: "https://broadinstitute.github.io/picard/"
+ tool_dev_url: "https://github.com/broadinstitute/picard"
+ licence: "['MIT']"
+input:
+ - meta:
+ type: map
+ description: |
+ Groovy Map containing sample information
+ e.g. [ id:'test', single_end:false ]
+ - bam:
+ type: file
+ description: BAM/CRAM/SAM file
+ pattern: "*.{bam,cram,sam}"
+output:
+ - meta:
+ type: map
+ description: |
+ Groovy Map containing sample information
+ e.g. [ id:'test', single_end:false ]
+ - versions:
+ type: file
+ description: File containing software versions
+ pattern: "versions.yml"
+ - pdf:
+ type: file
+ description: Histogram plots of the insert size metrics computed by Picard
+ pattern: "*.pdf"
+ - metrics:
+ type: file
+ description: Values used by Picard to generate the insert size histograms
+ pattern: "*.txt"
+authors:
+ - "@FerriolCalvet"
+maintainers:
+ - "@FerriolCalvet"
diff --git a/modules/nf-core/picard/collectwgsmetrics/environment.yml b/modules/nf-core/picard/collectwgsmetrics/environment.yml
new file mode 100644
index 00000000..8adda491
--- /dev/null
+++ b/modules/nf-core/picard/collectwgsmetrics/environment.yml
@@ -0,0 +1,8 @@
+name: picard_collectwgsmetrics
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::picard=3.1.0
+ - r::r-base
diff --git a/modules/nf-core/picard/collectwgsmetrics/main.nf b/modules/nf-core/picard/collectwgsmetrics/main.nf
index 1d59334c..67aa5b5e 100644
--- a/modules/nf-core/picard/collectwgsmetrics/main.nf
+++ b/modules/nf-core/picard/collectwgsmetrics/main.nf
@@ -2,10 +2,10 @@ process PICARD_COLLECTWGSMETRICS {
tag "$meta.id"
label 'process_single'
- conda "bioconda::picard=3.0.0 r::r-base"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/picard:3.0.0--hdfd78af_1' :
- 'biocontainers/picard:3.0.0--hdfd78af_1' }"
+ 'https://depot.galaxyproject.org/singularity/picard:3.1.0--hdfd78af_0' :
+ 'biocontainers/picard:3.1.0--hdfd78af_0' }"
input:
tuple val(meta), path(bam), path(bai)
diff --git a/modules/nf-core/picard/collectwgsmetrics/meta.yml b/modules/nf-core/picard/collectwgsmetrics/meta.yml
index 19906f08..5576ef92 100644
--- a/modules/nf-core/picard/collectwgsmetrics/meta.yml
+++ b/modules/nf-core/picard/collectwgsmetrics/meta.yml
@@ -68,3 +68,8 @@ authors:
- "@flowuenne"
- "@lassefolkersen"
- "@ramprasadn"
+maintainers:
+ - "@drpatelh"
+ - "@flowuenne"
+ - "@lassefolkersen"
+ - "@ramprasadn"
diff --git a/modules/nf-core/picard/markduplicates/main.nf b/modules/nf-core/picard/markduplicates/main.nf
deleted file mode 100644
index ebfa0864..00000000
--- a/modules/nf-core/picard/markduplicates/main.nf
+++ /dev/null
@@ -1,65 +0,0 @@
-process PICARD_MARKDUPLICATES {
- tag "$meta.id"
- label 'process_medium'
-
- conda "bioconda::picard=3.0.0"
- container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/picard:3.0.0--hdfd78af_1' :
- 'biocontainers/picard:3.0.0--hdfd78af_1' }"
-
- input:
- tuple val(meta), path(bam)
- tuple val(meta2), path(fasta)
- tuple val(meta3), path(fai)
-
- output:
- tuple val(meta), path("*.bam") , emit: bam
- tuple val(meta), path("*.bai") , optional:true, emit: bai
- tuple val(meta), path("*.metrics.txt"), emit: metrics
- path "versions.yml" , emit: versions
-
- when:
- task.ext.when == null || task.ext.when
-
- script:
- def args = task.ext.args ?: ''
- def prefix = task.ext.prefix ?: "${meta.id}"
- def avail_mem = 3072
- if (!task.memory) {
- log.info '[Picard MarkDuplicates] Available memory not known - defaulting to 3GB. Specify process memory requirements to change this.'
- } else {
- avail_mem = (task.memory.mega*0.8).intValue()
- }
-
- if ("$bam" == "${prefix}.bam") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!"
-
- """
- picard \\
- -Xmx${avail_mem}M \\
- MarkDuplicates \\
- $args \\
- --INPUT $bam \\
- --OUTPUT ${prefix}.bam \\
- --REFERENCE_SEQUENCE $fasta \\
- --METRICS_FILE ${prefix}.MarkDuplicates.metrics.txt
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- picard: \$(echo \$(picard MarkDuplicates --version 2>&1) | grep -o 'Version:.*' | cut -f2- -d:)
- END_VERSIONS
- """
-
- stub:
- def prefix = task.ext.prefix ?: "${meta.id}"
- if ("$bam" == "${prefix}.bam") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!"
- """
- touch ${prefix}.bam
- touch ${prefix}.bam.bai
- touch ${prefix}.MarkDuplicates.metrics.txt
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- picard: \$(echo \$(picard MarkDuplicates --version 2>&1) | grep -o 'Version:.*' | cut -f2- -d:)
- END_VERSIONS
- """
-}
diff --git a/modules/nf-core/picard/markduplicates/meta.yml b/modules/nf-core/picard/markduplicates/meta.yml
deleted file mode 100644
index f7693d2f..00000000
--- a/modules/nf-core/picard/markduplicates/meta.yml
+++ /dev/null
@@ -1,71 +0,0 @@
-name: picard_markduplicates
-description: Locate and tag duplicate reads in a BAM file
-keywords:
- - markduplicates
- - pcr
- - duplicates
- - bam
- - sam
- - cram
-tools:
- - picard:
- description: |
- A set of command line tools (in Java) for manipulating high-throughput sequencing (HTS)
- data and formats such as SAM/BAM/CRAM and VCF.
- homepage: https://broadinstitute.github.io/picard/
- documentation: https://broadinstitute.github.io/picard/
- licence: ["MIT"]
-input:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - bam:
- type: file
- description: BAM file
- pattern: "*.{bam,cram,sam}"
- - meta2:
- type: map
- description: |
- Groovy Map containing reference information
- e.g. [ id:'genome' ]
- - fasta:
- type: file
- description: Reference genome fasta file
- pattern: "*.{fasta,fa}"
- - meta3:
- type: map
- description: |
- Groovy Map containing reference information
- e.g. [ id:'genome' ]
- - fai:
- type: file
- description: Reference genome fasta index
- pattern: "*.{fai}"
-output:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - bam:
- type: file
- description: BAM file with duplicate reads marked/removed
- pattern: "*.{bam}"
- - bai:
- type: file
- description: An optional BAM index file. If desired, --CREATE_INDEX must be passed as a flag
- pattern: "*.{bai}"
- - metrics:
- type: file
- description: Duplicate metrics file generated by picard
- pattern: "*.{metrics.txt}"
- - versions:
- type: file
- description: File containing software versions
- pattern: "versions.yml"
-authors:
- - "@drpatelh"
- - "@projectoriented"
- - "@ramprasadn"
diff --git a/modules/nf-core/qualimap/rnaseq/main.nf b/modules/nf-core/qualimap/rnaseq/main.nf
deleted file mode 100644
index 044c983f..00000000
--- a/modules/nf-core/qualimap/rnaseq/main.nf
+++ /dev/null
@@ -1,63 +0,0 @@
-process QUALIMAP_RNASEQ {
- tag "$meta.id"
- label 'process_medium'
-
- conda "bioconda::qualimap=2.2.2d"
- container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/qualimap:2.2.2d--1' :
- 'biocontainers/qualimap:2.2.2d--1' }"
-
- input:
- tuple val(meta), path(bam)
- tuple val(meta2), path(gtf)
-
- output:
- tuple val(meta), path("${prefix}"), emit: results
- path "versions.yml" , emit: versions
-
- when:
- task.ext.when == null || task.ext.when
-
- script:
- def args = task.ext.args ?: ''
- prefix = task.ext.prefix ?: "${meta.id}"
- def paired_end = meta.single_end ? '' : '-pe'
- def memory = (task.memory.mega*0.8).intValue() + 'M'
-
- def strandedness = 'non-strand-specific'
- if (meta.strandedness == 'forward') {
- strandedness = 'strand-specific-forward'
- } else if (meta.strandedness == 'reverse') {
- strandedness = 'strand-specific-reverse'
- }
- """
- unset DISPLAY
- mkdir -p tmp
- export _JAVA_OPTIONS=-Djava.io.tmpdir=./tmp
- qualimap \\
- --java-mem-size=$memory \\
- rnaseq \\
- $args \\
- -bam $bam \\
- -gtf $gtf \\
- -p $strandedness \\
- $paired_end \\
- -outdir $prefix
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- qualimap: \$(echo \$(qualimap 2>&1) | sed 's/^.*QualiMap v.//; s/Built.*\$//')
- END_VERSIONS
- """
-
- stub:
- prefix = task.ext.prefix ?: "${meta.id}"
- """
- mkdir ${prefix}
-
- cat <<-END_VERSIONS > versions.yml
- "${task.process}":
- qualimap: \$(echo \$(qualimap 2>&1) | sed 's/^.*QualiMap v.//; s/Built.*\$//')
- END_VERSIONS
- """
-}
diff --git a/modules/nf-core/qualimap/rnaseq/meta.yml b/modules/nf-core/qualimap/rnaseq/meta.yml
deleted file mode 100644
index 7738f08d..00000000
--- a/modules/nf-core/qualimap/rnaseq/meta.yml
+++ /dev/null
@@ -1,52 +0,0 @@
-name: qualimap_rnaseq
-description: Evaluate alignment data
-keywords:
- - quality control
- - qc
- - rnaseq
-tools:
- - qualimap:
- description: |
- Qualimap 2 is a platform-independent application written in
- Java and R that provides both a Graphical User Interface and
- a command-line interface to facilitate the quality control of
- alignment sequencing data and its derivatives like feature counts.
- homepage: http://qualimap.bioinfo.cipf.es/
- documentation: http://qualimap.conesalab.org/doc_html/index.html
- doi: 10.1093/bioinformatics/bts503
- licence: ["GPL-2.0-only"]
-input:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - bam:
- type: file
- description: BAM file
- pattern: "*.{bam}"
- - meta2:
- type: map
- description: |
- Groovy Map containing reference information
- e.g. [ id:'test' ]
- - gtf:
- type: file
- description: GTF file of the reference genome
- pattern: "*.{gtf}"
-output:
- - meta:
- type: map
- description: |
- Groovy Map containing sample information
- e.g. [ id:'test', single_end:false ]
- - results:
- type: directory
- description: Qualimap results dir
- pattern: "*/*"
- - versions:
- type: file
- description: File containing software versions
- pattern: "versions.yml"
-authors:
- - "@FriederikeHanssen"
diff --git a/modules/nf-core/samtools/faidx/environment.yml b/modules/nf-core/samtools/faidx/environment.yml
new file mode 100644
index 00000000..73badedb
--- /dev/null
+++ b/modules/nf-core/samtools/faidx/environment.yml
@@ -0,0 +1,7 @@
+name: samtools_faidx
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::samtools=1.17
diff --git a/modules/nf-core/samtools/faidx/main.nf b/modules/nf-core/samtools/faidx/main.nf
index 59ed3088..3aa98822 100644
--- a/modules/nf-core/samtools/faidx/main.nf
+++ b/modules/nf-core/samtools/faidx/main.nf
@@ -2,7 +2,7 @@ process SAMTOOLS_FAIDX {
tag "$fasta"
label 'process_single'
- conda "bioconda::samtools=1.17"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' :
'biocontainers/samtools:1.17--h00cdaf9_0' }"
diff --git a/modules/nf-core/samtools/faidx/meta.yml b/modules/nf-core/samtools/faidx/meta.yml
index 957b25e5..e189af28 100644
--- a/modules/nf-core/samtools/faidx/meta.yml
+++ b/modules/nf-core/samtools/faidx/meta.yml
@@ -55,3 +55,7 @@ authors:
- "@drpatelh"
- "@ewels"
- "@phue"
+maintainers:
+ - "@drpatelh"
+ - "@ewels"
+ - "@phue"
diff --git a/modules/nf-core/samtools/index/environment.yml b/modules/nf-core/samtools/index/environment.yml
new file mode 100644
index 00000000..3c6f95b2
--- /dev/null
+++ b/modules/nf-core/samtools/index/environment.yml
@@ -0,0 +1,7 @@
+name: samtools_index
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::samtools=1.17
diff --git a/modules/nf-core/samtools/index/main.nf b/modules/nf-core/samtools/index/main.nf
index 0b20aa4b..256bd7c4 100644
--- a/modules/nf-core/samtools/index/main.nf
+++ b/modules/nf-core/samtools/index/main.nf
@@ -2,7 +2,7 @@ process SAMTOOLS_INDEX {
tag "$meta.id"
label 'process_low'
- conda "bioconda::samtools=1.17"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' :
'biocontainers/samtools:1.17--h00cdaf9_0' }"
diff --git a/modules/nf-core/samtools/index/meta.yml b/modules/nf-core/samtools/index/meta.yml
index 8bd2fa6f..01a4ee03 100644
--- a/modules/nf-core/samtools/index/meta.yml
+++ b/modules/nf-core/samtools/index/meta.yml
@@ -51,3 +51,7 @@ authors:
- "@drpatelh"
- "@ewels"
- "@maxulysse"
+maintainers:
+ - "@drpatelh"
+ - "@ewels"
+ - "@maxulysse"
diff --git a/modules/nf-core/samtools/index/tests/csi.nextflow.config b/modules/nf-core/samtools/index/tests/csi.nextflow.config
new file mode 100644
index 00000000..0ed260ef
--- /dev/null
+++ b/modules/nf-core/samtools/index/tests/csi.nextflow.config
@@ -0,0 +1,7 @@
+process {
+
+ withName: SAMTOOLS_INDEX {
+ ext.args = '-c'
+ }
+
+}
diff --git a/modules/nf-core/samtools/index/tests/main.nf.test b/modules/nf-core/samtools/index/tests/main.nf.test
new file mode 100644
index 00000000..c76a9169
--- /dev/null
+++ b/modules/nf-core/samtools/index/tests/main.nf.test
@@ -0,0 +1,87 @@
+nextflow_process {
+
+ name "Test Process SAMTOOLS_INDEX"
+ script "../main.nf"
+ process "SAMTOOLS_INDEX"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "samtools"
+ tag "samtools/index"
+
+ test("sarscov2 [BAI]") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test' ], // meta map
+ file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true)
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll (
+ { assert process.success },
+ { assert snapshot(process.out.bai).match("bai") },
+ { assert path(process.out.versions.get(0)).getText().contains("samtools") }
+ )
+ }
+ }
+
+ test("homo_sapiens [CRAI]") {
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test' ], // meta map
+ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_cram'], checkIfExists: true)
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll (
+ { assert process.success },
+ { assert snapshot(process.out.crai).match("crai") },
+ { assert path(process.out.versions.get(0)).getText().contains("samtools") }
+ )
+ }
+ }
+
+ test("homo_sapiens [CSI]") {
+
+ config "./csi.nextflow.config"
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test' ], // meta map
+ file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true)
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll (
+ { assert process.success },
+ { assert path(process.out.csi.get(0).get(1)).exists() },
+ { assert path(process.out.versions.get(0)).getText().contains("samtools") }
+ )
+ }
+ }
+}
diff --git a/modules/nf-core/samtools/index/tests/main.nf.test.snap b/modules/nf-core/samtools/index/tests/main.nf.test.snap
new file mode 100644
index 00000000..b3baee7f
--- /dev/null
+++ b/modules/nf-core/samtools/index/tests/main.nf.test.snap
@@ -0,0 +1,28 @@
+{
+ "crai": {
+ "content": [
+ [
+ [
+ {
+ "id": "test"
+ },
+ "test.paired_end.recalibrated.sorted.cram.crai:md5,14bc3bd5c89cacc8f4541f9062429029"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-15T15:17:37.30801"
+ },
+ "bai": {
+ "content": [
+ [
+ [
+ {
+ "id": "test"
+ },
+ "test.paired_end.sorted.bam.bai:md5,704c10dd1326482448ca3073fdebc2f4"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-15T15:17:30.869234"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/samtools/index/tests/tags.yml b/modules/nf-core/samtools/index/tests/tags.yml
new file mode 100644
index 00000000..e0f58a7a
--- /dev/null
+++ b/modules/nf-core/samtools/index/tests/tags.yml
@@ -0,0 +1,2 @@
+samtools/index:
+ - modules/nf-core/samtools/index/**
diff --git a/modules/nf-core/samtools/sort/environment.yml b/modules/nf-core/samtools/sort/environment.yml
new file mode 100644
index 00000000..508659f0
--- /dev/null
+++ b/modules/nf-core/samtools/sort/environment.yml
@@ -0,0 +1,7 @@
+name: samtools_sort
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::samtools=1.17
diff --git a/modules/nf-core/samtools/sort/main.nf b/modules/nf-core/samtools/sort/main.nf
index 2b7753fd..60f0c634 100644
--- a/modules/nf-core/samtools/sort/main.nf
+++ b/modules/nf-core/samtools/sort/main.nf
@@ -2,7 +2,7 @@ process SAMTOOLS_SORT {
tag "$meta.id"
label 'process_medium'
- conda "bioconda::samtools=1.17"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' :
'biocontainers/samtools:1.17--h00cdaf9_0' }"
diff --git a/modules/nf-core/samtools/sort/meta.yml b/modules/nf-core/samtools/sort/meta.yml
index 07328431..2200de72 100644
--- a/modules/nf-core/samtools/sort/meta.yml
+++ b/modules/nf-core/samtools/sort/meta.yml
@@ -46,3 +46,6 @@ output:
authors:
- "@drpatelh"
- "@ewels"
+maintainers:
+ - "@drpatelh"
+ - "@ewels"
diff --git a/modules/nf-core/samtools/sort/tests/main.nf.test b/modules/nf-core/samtools/sort/tests/main.nf.test
new file mode 100644
index 00000000..1f72f3b9
--- /dev/null
+++ b/modules/nf-core/samtools/sort/tests/main.nf.test
@@ -0,0 +1,70 @@
+nextflow_process {
+
+ name "Test Process SAMTOOLS_SORT"
+ script "../main.nf"
+ process "SAMTOOLS_SORT"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "samtools"
+ tag "samtools/sort"
+
+ test("test_samtools_sort") {
+
+ config "./nextflow.config"
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test', single_end:false ],
+ [
+ file(params.test_data['sarscov2']['illumina']['test_paired_end_bam'], checkIfExists: true)
+ ]
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll (
+ { assert process.success },
+ { assert snapshot(process.out).match() }
+ )
+ }
+
+ }
+
+ test("test_samtools_sort_stub") {
+
+ config "./nextflow.config"
+ options "-stub-run"
+
+ when {
+ params {
+ outdir = "$outputDir"
+ }
+ process {
+ """
+ input[0] = [
+ [ id:'test', single_end:false ],
+ [
+ file(params.test_data['sarscov2']['illumina']['test_paired_end_bam'], checkIfExists: true)
+ ]
+ ]
+ """
+ }
+ }
+
+ then {
+ assertAll (
+ { assert process.success },
+ { assert snapshot(process.out).match() }
+ )
+ }
+
+ }
+
+}
diff --git a/modules/nf-core/samtools/sort/tests/main.nf.test.snap b/modules/nf-core/samtools/sort/tests/main.nf.test.snap
new file mode 100644
index 00000000..a43566da
--- /dev/null
+++ b/modules/nf-core/samtools/sort/tests/main.nf.test.snap
@@ -0,0 +1,39 @@
+{
+ "test_samtools_sort": {
+ "content": [
+ {
+ "0": [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.sorted.bam:md5,a29570e7607d217c2fa4d75829e09cd7"
+ ]
+ ],
+ "1": [
+
+ ],
+ "2": [
+ "versions.yml:md5,46f7a36082fa1f68285fe30d689244e8"
+ ],
+ "bam": [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.sorted.bam:md5,a29570e7607d217c2fa4d75829e09cd7"
+ ]
+ ],
+ "csi": [
+
+ ],
+ "versions": [
+ "versions.yml:md5,46f7a36082fa1f68285fe30d689244e8"
+ ]
+ }
+ ],
+ "timestamp": "2023-10-17T17:21:46.5427968"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/samtools/sort/tests/nextflow.config b/modules/nf-core/samtools/sort/tests/nextflow.config
new file mode 100644
index 00000000..d0f35086
--- /dev/null
+++ b/modules/nf-core/samtools/sort/tests/nextflow.config
@@ -0,0 +1,7 @@
+process {
+
+ withName: SAMTOOLS_SORT {
+ ext.prefix = { "${meta.id}.sorted" }
+ }
+
+}
diff --git a/modules/nf-core/samtools/sort/tests/tags.yml b/modules/nf-core/samtools/sort/tests/tags.yml
new file mode 100644
index 00000000..cd63ea20
--- /dev/null
+++ b/modules/nf-core/samtools/sort/tests/tags.yml
@@ -0,0 +1,3 @@
+samtools/sort:
+ - modules/nf-core/samtools/sort/**
+ - tests/modules/nf-core/samtools/sort/**
diff --git a/modules/nf-core/samtools/view/environment.yml b/modules/nf-core/samtools/view/environment.yml
new file mode 100644
index 00000000..141e7bd8
--- /dev/null
+++ b/modules/nf-core/samtools/view/environment.yml
@@ -0,0 +1,7 @@
+name: samtools_view
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::samtools=1.17
diff --git a/modules/nf-core/samtools/view/main.nf b/modules/nf-core/samtools/view/main.nf
index cb91facf..ddf3f88a 100644
--- a/modules/nf-core/samtools/view/main.nf
+++ b/modules/nf-core/samtools/view/main.nf
@@ -2,7 +2,7 @@ process SAMTOOLS_VIEW {
tag "$meta.id"
label 'process_low'
- conda "bioconda::samtools=1.17"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' :
'biocontainers/samtools:1.17--h00cdaf9_0' }"
diff --git a/modules/nf-core/samtools/view/meta.yml b/modules/nf-core/samtools/view/meta.yml
index 3b05450b..3dadafae 100644
--- a/modules/nf-core/samtools/view/meta.yml
+++ b/modules/nf-core/samtools/view/meta.yml
@@ -82,3 +82,8 @@ authors:
- "@joseespinosa"
- "@FriederikeHanssen"
- "@priyanka-surana"
+maintainers:
+ - "@drpatelh"
+ - "@joseespinosa"
+ - "@FriederikeHanssen"
+ - "@priyanka-surana"
diff --git a/modules/nf-core/star/align/environment.yml b/modules/nf-core/star/align/environment.yml
new file mode 100644
index 00000000..6db20988
--- /dev/null
+++ b/modules/nf-core/star/align/environment.yml
@@ -0,0 +1,9 @@
+name: star_align
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::star=2.7.10a
+ - bioconda::samtools=1.16.1
+ - conda-forge::gawk=5.1.0
diff --git a/modules/nf-core/star/align/main.nf b/modules/nf-core/star/align/main.nf
index d0e20384..cc4f5af5 100644
--- a/modules/nf-core/star/align/main.nf
+++ b/modules/nf-core/star/align/main.nf
@@ -2,10 +2,10 @@ process STAR_ALIGN {
tag "$meta.id"
label 'process_high'
- conda "bioconda::star=2.7.10a bioconda::samtools=1.16.1 conda-forge::gawk=5.1.0"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:1df389393721fc66f3fd8778ad938ac711951107-0' :
- 'biocontainers/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:1df389393721fc66f3fd8778ad938ac711951107-0' }"
+ 'https://depot.galaxyproject.org/singularity/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:019f262d90511939dce2dca4b7c868fc108f73db-0' :
+ 'biocontainers/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:019f262d90511939dce2dca4b7c868fc108f73db-0' }"
input:
tuple val(meta), path(reads, stageAs: "input*/*")
diff --git a/modules/nf-core/star/align/meta.yml b/modules/nf-core/star/align/meta.yml
index 3d8fed0c..e80dbb7d 100644
--- a/modules/nf-core/star/align/meta.yml
+++ b/modules/nf-core/star/align/meta.yml
@@ -52,7 +52,6 @@ input:
- seq_center:
type: string
description: Sequencing center
-
output:
- bam:
type: file
@@ -106,8 +105,11 @@ output:
type: file
description: STAR output bedGraph format file(s) (optional)
pattern: "*.bg"
-
authors:
- "@kevinmenden"
- "@drpatelh"
- "@praveenraj2018"
+maintainers:
+ - "@kevinmenden"
+ - "@drpatelh"
+ - "@praveenraj2018"
diff --git a/modules/nf-core/star/align/tests/main.nf.test b/modules/nf-core/star/align/tests/main.nf.test
new file mode 100644
index 00000000..4c878474
--- /dev/null
+++ b/modules/nf-core/star/align/tests/main.nf.test
@@ -0,0 +1,339 @@
+nextflow_process {
+
+ name "Test Process STAR_ALIGN"
+ script "../main.nf"
+ process "STAR_ALIGN"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "star"
+ tag "star/align"
+
+ test("homo_sapiens - single_end") {
+ config "./nextflow.config"
+
+ setup {
+ run("STAR_GENOMEGENERATE") {
+ script "../../../star/genomegenerate/main.nf"
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test_fasta' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)]
+ ])
+ input[1] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ """
+ }
+ }
+ }
+
+ when {
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test', single_end:true ], // meta map
+ [ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_1_fastq_gz'], checkIfExists: true) ]
+ ])
+ input[1] = STAR_GENOMEGENERATE.out.index
+ input[2] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ input[3] = false
+ input[4] = 'illumina'
+ input[5] = false
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(file(process.out.log_final[0][1]).name).match("homo_sapiens - single_end - log_final") },
+ { assert snapshot(file(process.out.log_out[0][1]).name).match("homo_sapiens - single_end - log_out") },
+ { assert snapshot(process.out.bam).match("homo_sapiens - single_end - bam") },
+ { assert snapshot(process.out.bam_sorted).match("homo_sapiens - single_end - bam_sorted") },
+ { assert snapshot(process.out.bam_transcript).match("homo_sapiens - single_end - bam_transcript") },
+ { assert snapshot(process.out.bam_unsorted).match("homo_sapiens - single_end - bam_unsorted") },
+ { assert snapshot(process.out.bedgraph).match("homo_sapiens - single_end - bedgraph") },
+ { assert snapshot(process.out.fastq).match("homo_sapiens - single_end - fastq") },
+ { assert snapshot(process.out.junction).match("homo_sapiens - single_end - junction") },
+ { assert snapshot(process.out.log_progress).match("homo_sapiens - single_end - log_progress") },
+ { assert snapshot(process.out.read_per_gene_tab).match("homo_sapiens - single_end - read_per_gene_tab") },
+ { assert snapshot(process.out.sam).match("homo_sapiens - single_end - sam") },
+ { assert snapshot(process.out.spl_junc_tab).match("homo_sapiens - single_end - spl_junc_tab") },
+ { assert snapshot(process.out.tab).match("homo_sapiens - single_end - tab") },
+ { assert snapshot(process.out.wig).match("homo_sapiens - single_end - wig") },
+ { assert snapshot(process.out.versions).match("homo_sapiens - single_end - versions") }
+ )
+ }
+ }
+
+ test("homo_sapiens - paired_end") {
+ config "./nextflow.config"
+
+ setup {
+ run("STAR_GENOMEGENERATE") {
+ script "../../../star/genomegenerate/main.nf"
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test_fasta' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)]
+ ])
+ input[1] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ """
+ }
+ }
+ }
+
+ when {
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test', single_end:false ], // meta map
+ [
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_2_fastq_gz'], checkIfExists: true)
+ ]
+ ])
+ input[1] = STAR_GENOMEGENERATE.out.index
+ input[2] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ input[3] = false
+ input[4] = 'illumina'
+ input[5] = false
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(file(process.out.log_final[0][1]).name).match("homo_sapiens - paired_end - log_final") },
+ { assert snapshot(file(process.out.log_out[0][1]).name).match("homo_sapiens - paired_end - log_out") },
+ { assert snapshot(process.out.bam).match("homo_sapiens - paired_end - bam") },
+ { assert snapshot(process.out.bam_sorted).match("homo_sapiens - paired_end - bam_sorted") },
+ { assert snapshot(process.out.bam_transcript).match("homo_sapiens - paired_end - bam_transcript") },
+ { assert snapshot(process.out.bam_unsorted).match("homo_sapiens - paired_end - bam_unsorted") },
+ { assert snapshot(process.out.bedgraph).match("homo_sapiens - paired_end - bedgraph") },
+ { assert snapshot(process.out.fastq).match("homo_sapiens - paired_end - fastq") },
+ { assert snapshot(process.out.junction).match("homo_sapiens - paired_end - junction") },
+ { assert snapshot(process.out.log_progress).match("homo_sapiens - paired_end - log_progress") },
+ { assert snapshot(process.out.read_per_gene_tab).match("homo_sapiens - paired_end - read_per_gene_tab") },
+ { assert snapshot(process.out.sam).match("homo_sapiens - paired_end - sam") },
+ { assert snapshot(process.out.spl_junc_tab).match("homo_sapiens - paired_end - spl_junc_tab") },
+ { assert snapshot(process.out.tab).match("homo_sapiens - paired_end - tab") },
+ { assert snapshot(process.out.wig).match("homo_sapiens - paired_end - wig") },
+ { assert snapshot(process.out.versions).match("homo_sapiens - paired_end - versions") }
+ )
+ }
+ }
+
+ test("homo_sapiens - paired_end - arriba") {
+ config "./nextflow.arriba.config"
+
+ setup {
+ run("STAR_GENOMEGENERATE") {
+ script "../../../star/genomegenerate/main.nf"
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test_fasta' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)]
+ ])
+ input[1] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ """
+ }
+ }
+ }
+
+ when {
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test', single_end:false ], // meta map
+ [
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_2_fastq_gz'], checkIfExists: true)
+ ]
+ ])
+ input[1] = STAR_GENOMEGENERATE.out.index
+ input[2] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ input[3] = false
+ input[4] = 'illumina'
+ input[5] = false
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(file(process.out.log_final[0][1]).name).match("homo_sapiens - paired_end - arriba - log_final") },
+ { assert snapshot(file(process.out.log_out[0][1]).name).match("homo_sapiens - paired_end - arriba - log_out") },
+ { assert snapshot(file(process.out.log_progress[0][1]).name).match("homo_sapiens - paired_end - arriba - log_progress") },
+ { assert snapshot(process.out.bam).match("homo_sapiens - paired_end - arriba - bam") },
+ { assert snapshot(process.out.bam_sorted).match("homo_sapiens - paired_end - arriba - bam_sorted") },
+ { assert snapshot(process.out.bam_transcript).match("homo_sapiens - paired_end - arriba - bam_transcript") },
+ { assert snapshot(process.out.bam_unsorted).match("homo_sapiens - paired_end - arriba - bam_unsorted") },
+ { assert snapshot(process.out.bedgraph).match("homo_sapiens - paired_end - arriba - bedgraph") },
+ { assert snapshot(process.out.fastq).match("homo_sapiens - paired_end - arriba - fastq") },
+ { assert snapshot(process.out.junction).match("homo_sapiens - paired_end - arriba - junction") },
+ { assert snapshot(process.out.read_per_gene_tab).match("homo_sapiens - paired_end - arriba - read_per_gene_tab") },
+ { assert snapshot(process.out.sam).match("homo_sapiens - paired_end - arriba - sam") },
+ { assert snapshot(process.out.spl_junc_tab).match("homo_sapiens - paired_end - arriba - spl_junc_tab") },
+ { assert snapshot(process.out.tab).match("homo_sapiens - paired_end - arriba - tab") },
+ { assert snapshot(process.out.wig).match("homo_sapiens - paired_end - arriba - wig") },
+ { assert snapshot(process.out.versions).match("homo_sapiens - paired_end - arriba - versions") }
+ )
+ }
+ }
+
+ test("homo_sapiens - paired_end - starfusion") {
+ config "./nextflow.starfusion.config"
+
+ setup {
+ run("STAR_GENOMEGENERATE") {
+ script "../../../star/genomegenerate/main.nf"
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test_fasta' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)]
+ ])
+ input[1] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ """
+ }
+ }
+ }
+
+ when {
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test', single_end:false ], // meta map
+ [
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_2_fastq_gz'], checkIfExists: true)
+ ]
+ ])
+ input[1] = STAR_GENOMEGENERATE.out.index
+ input[2] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ input[3] = false
+ input[4] = 'illumina'
+ input[5] = false
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(file(process.out.log_final[0][1]).name).match("homo_sapiens - paired_end - starfusion - log_final") },
+ { assert snapshot(file(process.out.log_out[0][1]).name).match("homo_sapiens - paired_end - starfusion - log_out") },
+ { assert snapshot(file(process.out.log_progress[0][1]).name).match("homo_sapiens - paired_end - starfusion - log_progress") },
+ { assert snapshot(process.out.bam).match("homo_sapiens - paired_end - starfusion - bam") },
+ { assert snapshot(process.out.bam_sorted).match("homo_sapiens - paired_end - starfusion - bam_sorted") },
+ { assert snapshot(process.out.bam_transcript).match("homo_sapiens - paired_end - starfusion - bam_transcript") },
+ { assert snapshot(process.out.bam_unsorted).match("homo_sapiens - paired_end - starfusion - bam_unsorted") },
+ { assert snapshot(process.out.bedgraph).match("homo_sapiens - paired_end - starfusion - bedgraph") },
+ { assert snapshot(process.out.fastq).match("homo_sapiens - paired_end - starfusion - fastq") },
+ { assert snapshot(process.out.junction).match("homo_sapiens - paired_end - starfusion - junction") },
+ { assert snapshot(process.out.read_per_gene_tab).match("homo_sapiens - paired_end - starfusion - read_per_gene_tab") },
+ { assert snapshot(process.out.sam).match("homo_sapiens - paired_end - starfusion - sam") },
+ { assert snapshot(process.out.spl_junc_tab).match("homo_sapiens - paired_end - starfusion - spl_junc_tab") },
+ { assert snapshot(process.out.tab).match("homo_sapiens - paired_end - starfusion - tab") },
+ { assert snapshot(process.out.wig).match("homo_sapiens - paired_end - starfusion - wig") },
+ { assert snapshot(process.out.versions).match("homo_sapiens - paired_end - starfusion - versions") }
+ )
+ }
+ }
+
+ test("homo_sapiens - paired_end - multiple") {
+ config "./nextflow.config"
+
+ setup {
+ run("STAR_GENOMEGENERATE") {
+ script "../../../star/genomegenerate/main.nf"
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test_fasta' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)]
+ ])
+ input[1] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ """
+ }
+ }
+ }
+
+ when {
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test', single_end:false ], // meta map
+ [
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_2_fastq_gz'], checkIfExists: true),
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_1_fastq_gz'], checkIfExists: true),
+ file(params.test_data['homo_sapiens']['illumina']['test_rnaseq_2_fastq_gz'], checkIfExists: true)
+ ]
+ ])
+ input[1] = STAR_GENOMEGENERATE.out.index
+ input[2] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ input[3] = false
+ input[4] = 'illumina'
+ input[5] = false
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(file(process.out.log_final[0][1]).name).match("homo_sapiens - paired_end - multiple - log_final") },
+ { assert snapshot(file(process.out.log_out[0][1]).name).match("homo_sapiens - paired_end - multiple - log_out") },
+ { assert snapshot(file(process.out.log_progress[0][1]).name).match("homo_sapiens - paired_end - multiple - log_progress") },
+ { assert snapshot(process.out.bam).match("homo_sapiens - paired_end - multiple - bam") },
+ { assert snapshot(process.out.bam_sorted).match("homo_sapiens - paired_end - multiple - bam_sorted") },
+ { assert snapshot(process.out.bam_transcript).match("homo_sapiens - paired_end - multiple - bam_transcript") },
+ { assert snapshot(process.out.bam_unsorted).match("homo_sapiens - paired_end - multiple - bam_unsorted") },
+ { assert snapshot(process.out.bedgraph).match("homo_sapiens - paired_end - multiple - bedgraph") },
+ { assert snapshot(process.out.fastq).match("homo_sapiens - paired_end - multiple - fastq") },
+ { assert snapshot(process.out.junction).match("homo_sapiens - paired_end - multiple - junction") },
+ { assert snapshot(process.out.read_per_gene_tab).match("homo_sapiens - paired_end - multiple - read_per_gene_tab") },
+ { assert snapshot(process.out.sam).match("homo_sapiens - paired_end - multiple - sam") },
+ { assert snapshot(process.out.spl_junc_tab).match("homo_sapiens - paired_end - multiple - spl_junc_tab") },
+ { assert snapshot(process.out.tab).match("homo_sapiens - paired_end - multiple - tab") },
+ { assert snapshot(process.out.wig).match("homo_sapiens - paired_end - multiple - wig") },
+ { assert snapshot(process.out.versions).match("homo_sapiens - paired_end - multiple - versions") }
+ )
+ }
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/star/align/tests/main.nf.test.snap b/modules/nf-core/star/align/tests/main.nf.test.snap
new file mode 100644
index 00000000..59b735d4
--- /dev/null
+++ b/modules/nf-core/star/align/tests/main.nf.test.snap
@@ -0,0 +1,769 @@
+{
+ "homo_sapiens - paired_end - multiple - bam_sorted": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.Aligned.sortedByCoord.out.bam:md5,ab07c21d63ab0a6c07d171d213c81d5a"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.19639"
+ },
+ "homo_sapiens - paired_end - multiple - wig": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.857804"
+ },
+ "homo_sapiens - paired_end - arriba - tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.SJ.out.tab:md5,5155c9fd1f787ad6d7d80987fb06219c"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.396223"
+ },
+ "homo_sapiens - single_end - wig": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.24701"
+ },
+ "homo_sapiens - paired_end - sam": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.383818"
+ },
+ "homo_sapiens - paired_end - arriba - versions": {
+ "content": [
+ [
+ "versions.yml:md5,452ef035aacbc68d47041e86279a9333"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.494015"
+ },
+ "homo_sapiens - paired_end - multiple - bedgraph": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ [
+ "test.Signal.Unique.str1.out.bg:md5,d7bf8b70b436ca048a62513e1d0ece3a",
+ "test.Signal.UniqueMultiple.str1.out.bg:md5,686d58493b9eb445b56ace4d67f76ef6"
+ ]
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.396383"
+ },
+ "homo_sapiens - paired_end - read_per_gene_tab": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.368841"
+ },
+ "homo_sapiens - paired_end - arriba - bedgraph": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.102537"
+ },
+ "homo_sapiens - single_end - junction": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.185369"
+ },
+ "homo_sapiens - paired_end - arriba - spl_junc_tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.SJ.out.tab:md5,5155c9fd1f787ad6d7d80987fb06219c"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.348239"
+ },
+ "homo_sapiens - single_end - sam": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.216183"
+ },
+ "homo_sapiens - paired_end - fastq": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.327236"
+ },
+ "homo_sapiens - single_end - versions": {
+ "content": [
+ [
+ "versions.yml:md5,452ef035aacbc68d47041e86279a9333"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.259282"
+ },
+ "homo_sapiens - paired_end - multiple - log_out": {
+ "content": [
+ "test.Log.out"
+ ],
+ "timestamp": "2023-11-23T13:29:01.022176"
+ },
+ "homo_sapiens - paired_end - arriba - fastq": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.15277"
+ },
+ "homo_sapiens - paired_end - multiple - junction": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.52923"
+ },
+ "homo_sapiens - paired_end - multiple - spl_junc_tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.SJ.out.tab:md5,069877e053714e23010fe4e1c003b4a2"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.729175"
+ },
+ "homo_sapiens - paired_end - starfusion - log_final": {
+ "content": [
+ "test.Log.final.out"
+ ],
+ "timestamp": "2023-11-23T13:27:55.905883"
+ },
+ "homo_sapiens - paired_end - starfusion - fastq": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.192302"
+ },
+ "homo_sapiens - paired_end - multiple - sam": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.661837"
+ },
+ "homo_sapiens - paired_end - multiple - log_final": {
+ "content": [
+ "test.Log.final.out"
+ ],
+ "timestamp": "2023-11-23T13:29:00.966417"
+ },
+ "homo_sapiens - paired_end - starfusion - bam": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.Aligned.out.bam:md5,bcad07b838f6762fc01eea52b5cd3f84"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.003675"
+ },
+ "homo_sapiens - paired_end - arriba - junction": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.202776"
+ },
+ "homo_sapiens - single_end - bedgraph": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ [
+ "test.Signal.Unique.str1.out.bg:md5,c56fc1472776fb927eaf62d973da5f9a",
+ "test.Signal.UniqueMultiple.str1.out.bg:md5,e93373cf6f2a2a9506e2efdb260cdd4f"
+ ]
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.163495"
+ },
+ "homo_sapiens - paired_end - arriba - read_per_gene_tab": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.251962"
+ },
+ "homo_sapiens - paired_end - starfusion - bam_sorted": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.040843"
+ },
+ "homo_sapiens - single_end - bam_unsorted": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.154172"
+ },
+ "homo_sapiens - paired_end - bam": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.Aligned.sortedByCoord.out.bam:md5,b9ee1c607e07323bc1652ef3babb543f"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.265265"
+ },
+ "homo_sapiens - paired_end - arriba - bam_transcript": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:06.998817"
+ },
+ "homo_sapiens - paired_end - log_out": {
+ "content": [
+ "test.Log.out"
+ ],
+ "timestamp": "2023-11-23T13:23:33.259699"
+ },
+ "homo_sapiens - paired_end - arriba - log_out": {
+ "content": [
+ "test.Log.out"
+ ],
+ "timestamp": "2023-11-23T13:25:06.849451"
+ },
+ "homo_sapiens - paired_end - multiple - versions": {
+ "content": [
+ [
+ "versions.yml:md5,452ef035aacbc68d47041e86279a9333"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.937182"
+ },
+ "homo_sapiens - paired_end - starfusion - bam_transcript": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.082408"
+ },
+ "homo_sapiens - paired_end - starfusion - tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.SJ.out.tab:md5,19c3faa1bfa9a0cc5e4c45f17065b53a"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.379367"
+ },
+ "homo_sapiens - single_end - fastq": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.175307"
+ },
+ "homo_sapiens - paired_end - tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.SJ.out.tab:md5,844af19ab0fc8cd9a3f75228445aca0d"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.413683"
+ },
+ "homo_sapiens - paired_end - starfusion - bedgraph": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.155413"
+ },
+ "homo_sapiens - single_end - bam_transcript": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.144852"
+ },
+ "homo_sapiens - paired_end - versions": {
+ "content": [
+ [
+ "versions.yml:md5,452ef035aacbc68d47041e86279a9333"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.445323"
+ },
+ "homo_sapiens - paired_end - multiple - tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.SJ.out.tab:md5,069877e053714e23010fe4e1c003b4a2"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.793129"
+ },
+ "homo_sapiens - single_end - bam": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.Aligned.sortedByCoord.out.bam:md5,c6cfaccaf91bc7fdabed3cfe236d4535"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.128568"
+ },
+ "homo_sapiens - paired_end - arriba - wig": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.444214"
+ },
+ "homo_sapiens - paired_end - log_progress": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.Log.progress.out:md5,b2bd061d6cbaaf3d6d3b1fed547f69b8"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.354416"
+ },
+ "homo_sapiens - paired_end - arriba - log_final": {
+ "content": [
+ "test.Log.final.out"
+ ],
+ "timestamp": "2023-11-23T13:25:06.829799"
+ },
+ "homo_sapiens - paired_end - bam_unsorted": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.300509"
+ },
+ "homo_sapiens - paired_end - arriba - sam": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.300383"
+ },
+ "homo_sapiens - paired_end - multiple - bam": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.Aligned.sortedByCoord.out.bam:md5,ab07c21d63ab0a6c07d171d213c81d5a"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.13168"
+ },
+ "homo_sapiens - paired_end - multiple - fastq": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.462257"
+ },
+ "homo_sapiens - single_end - bam_sorted": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.Aligned.sortedByCoord.out.bam:md5,c6cfaccaf91bc7fdabed3cfe236d4535"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.134799"
+ },
+ "homo_sapiens - paired_end - arriba - bam_sorted": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:06.94699"
+ },
+ "homo_sapiens - paired_end - starfusion - junction": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.Chimeric.out.junction:md5,c10ef219f4a30e83711b995bc5e40dba"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.228327"
+ },
+ "homo_sapiens - single_end - tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.SJ.out.tab:md5,75a516ab950fb958f40b29996474949c"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.236346"
+ },
+ "homo_sapiens - paired_end - starfusion - versions": {
+ "content": [
+ [
+ "versions.yml:md5,452ef035aacbc68d47041e86279a9333"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.460903"
+ },
+ "homo_sapiens - paired_end - multiple - bam_unsorted": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.330463"
+ },
+ "homo_sapiens - paired_end - arriba - log_progress": {
+ "content": [
+ "test.Log.progress.out"
+ ],
+ "timestamp": "2023-11-23T13:25:06.86866"
+ },
+ "homo_sapiens - paired_end - bedgraph": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ [
+ "test.Signal.Unique.str1.out.bg:md5,d7bf8b70b436ca048a62513e1d0ece3a",
+ "test.Signal.UniqueMultiple.str1.out.bg:md5,686d58493b9eb445b56ace4d67f76ef6"
+ ]
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.313258"
+ },
+ "homo_sapiens - paired_end - starfusion - bam_unsorted": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.118974"
+ },
+ "homo_sapiens - paired_end - starfusion - read_per_gene_tab": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.264699"
+ },
+ "homo_sapiens - paired_end - multiple - log_progress": {
+ "content": [
+ "test.Log.progress.out"
+ ],
+ "timestamp": "2023-11-23T13:29:01.076947"
+ },
+ "homo_sapiens - paired_end - arriba - bam_unsorted": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:07.050409"
+ },
+ "homo_sapiens - paired_end - bam_sorted": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.Aligned.sortedByCoord.out.bam:md5,b9ee1c607e07323bc1652ef3babb543f"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.274809"
+ },
+ "homo_sapiens - single_end - spl_junc_tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.SJ.out.tab:md5,75a516ab950fb958f40b29996474949c"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.226143"
+ },
+ "homo_sapiens - paired_end - starfusion - spl_junc_tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.SJ.out.tab:md5,19c3faa1bfa9a0cc5e4c45f17065b53a"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.337072"
+ },
+ "homo_sapiens - single_end - log_out": {
+ "content": [
+ "test.Log.out"
+ ],
+ "timestamp": "2023-11-23T13:22:55.126286"
+ },
+ "homo_sapiens - paired_end - log_final": {
+ "content": [
+ "test.Log.final.out"
+ ],
+ "timestamp": "2023-11-23T13:23:33.253884"
+ },
+ "homo_sapiens - single_end - log_final": {
+ "content": [
+ "test.Log.final.out"
+ ],
+ "timestamp": "2023-11-23T13:22:55.11799"
+ },
+ "homo_sapiens - paired_end - bam_transcript": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.287684"
+ },
+ "homo_sapiens - paired_end - starfusion - log_progress": {
+ "content": [
+ "test.Log.progress.out"
+ ],
+ "timestamp": "2023-11-23T13:27:55.971484"
+ },
+ "homo_sapiens - paired_end - multiple - bam_transcript": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.264176"
+ },
+ "homo_sapiens - paired_end - multiple - read_per_gene_tab": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:29:01.596406"
+ },
+ "homo_sapiens - single_end - read_per_gene_tab": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.205936"
+ },
+ "homo_sapiens - paired_end - junction": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.340653"
+ },
+ "homo_sapiens - paired_end - spl_junc_tab": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.SJ.out.tab:md5,844af19ab0fc8cd9a3f75228445aca0d"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.398603"
+ },
+ "homo_sapiens - paired_end - starfusion - sam": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.300637"
+ },
+ "homo_sapiens - paired_end - arriba - bam": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": false
+ },
+ "test.Aligned.out.bam:md5,c1b1747f5873f2d17762725636e891d5"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:25:06.887604"
+ },
+ "homo_sapiens - single_end - log_progress": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "single_end": true
+ },
+ "test.Log.progress.out:md5,b2bd061d6cbaaf3d6d3b1fed547f69b8"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:22:55.195544"
+ },
+ "homo_sapiens - paired_end - starfusion - wig": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:27:56.422018"
+ },
+ "homo_sapiens - paired_end - wig": {
+ "content": [
+ [
+
+ ]
+ ],
+ "timestamp": "2023-11-23T13:23:33.429457"
+ },
+ "homo_sapiens - paired_end - starfusion - log_out": {
+ "content": [
+ "test.Log.out"
+ ],
+ "timestamp": "2023-11-23T13:27:55.93945"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/star/align/tests/nextflow.arriba.config b/modules/nf-core/star/align/tests/nextflow.arriba.config
new file mode 100644
index 00000000..2324b9e5
--- /dev/null
+++ b/modules/nf-core/star/align/tests/nextflow.arriba.config
@@ -0,0 +1,14 @@
+process {
+
+ withName: STAR_GENOMEGENERATE {
+ ext.args = '--genomeSAindexNbases 9'
+ }
+
+ withName: STAR_ALIGN {
+ ext.args = '--readFilesCommand zcat --outSAMtype BAM Unsorted --outSAMunmapped Within --outBAMcompression 0 --outFilterMultimapNmax 50 --peOverlapNbasesMin 10 --alignSplicedMateMapLminOverLmate 0.5 --alignSJstitchMismatchNmax 5 -1 5 5 --chimSegmentMin 10 --chimOutType WithinBAM HardClip --chimJunctionOverhangMin 10 --chimScoreDropMax 30 --chimScoreJunctionNonGTAG 0 --chimScoreSeparation 1 --chimSegmentReadGapMax 3 --chimMultimapNmax 50'
+ }
+
+}
+
+// Fix chown issue for the output star folder
+docker.runOptions = '--platform=linux/amd64 -u $(id -u):$(id -g)'
diff --git a/modules/nf-core/star/align/tests/nextflow.config b/modules/nf-core/star/align/tests/nextflow.config
new file mode 100644
index 00000000..c4ac5808
--- /dev/null
+++ b/modules/nf-core/star/align/tests/nextflow.config
@@ -0,0 +1,14 @@
+process {
+
+ withName: STAR_GENOMEGENERATE {
+ ext.args = '--genomeSAindexNbases 9'
+ }
+
+ withName: STAR_ALIGN {
+ ext.args = '--readFilesCommand zcat --outSAMtype BAM SortedByCoordinate --outWigType bedGraph --outWigStrand Unstranded'
+ }
+
+}
+
+// Fix chown issue for the output star folder
+docker.runOptions = '--platform=linux/amd64 -u $(id -u):$(id -g)'
diff --git a/modules/nf-core/star/align/tests/nextflow.starfusion.config b/modules/nf-core/star/align/tests/nextflow.starfusion.config
new file mode 100644
index 00000000..467b6497
--- /dev/null
+++ b/modules/nf-core/star/align/tests/nextflow.starfusion.config
@@ -0,0 +1,14 @@
+process {
+
+ withName: STAR_GENOMEGENERATE {
+ ext.args = '--genomeSAindexNbases 9'
+ }
+
+ withName: STAR_ALIGN {
+ ext.args = '--readFilesCommand zcat --outSAMtype BAM Unsorted --outReadsUnmapped None --twopassMode Basic --outSAMstrandField intronMotif --outSAMunmapped Within --chimSegmentMin 12 --chimJunctionOverhangMin 8 --chimOutJunctionFormat 1 --alignSJDBoverhangMin 10 --alignMatesGapMax 100000 --alignIntronMax 100000 --alignSJstitchMismatchNmax 5 -1 5 5 --chimMultimapScoreRange 3 --chimScoreJunctionNonGTAG -4 --chimMultimapNmax 20 --chimNonchimScoreDropMin 10 --peOverlapNbasesMin 12 --peOverlapMMp 0.1 --alignInsertionFlush Right --alignSplicedMateMapLminOverLmate 0 --alignSplicedMateMapLmin 30'
+ }
+
+}
+
+// Fix chown issue for the output star folder
+docker.runOptions = '--platform=linux/amd64 -u $(id -u):$(id -g)'
diff --git a/modules/nf-core/star/align/tests/tags.yml b/modules/nf-core/star/align/tests/tags.yml
new file mode 100644
index 00000000..8beace16
--- /dev/null
+++ b/modules/nf-core/star/align/tests/tags.yml
@@ -0,0 +1,2 @@
+star/align:
+ - modules/nf-core/star/align/**
diff --git a/modules/nf-core/star/genomegenerate/environment.yml b/modules/nf-core/star/genomegenerate/environment.yml
new file mode 100644
index 00000000..0b35ff51
--- /dev/null
+++ b/modules/nf-core/star/genomegenerate/environment.yml
@@ -0,0 +1,9 @@
+name: star_genomegenerate
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::star=2.7.10a
+ - bioconda::samtools=1.16.1
+ - conda-forge::gawk=5.1.0
diff --git a/modules/nf-core/star/genomegenerate/main.nf b/modules/nf-core/star/genomegenerate/main.nf
index 43424042..d2061844 100644
--- a/modules/nf-core/star/genomegenerate/main.nf
+++ b/modules/nf-core/star/genomegenerate/main.nf
@@ -2,10 +2,10 @@ process STAR_GENOMEGENERATE {
tag "$fasta"
label 'process_high'
- conda "bioconda::star=2.7.10a bioconda::samtools=1.16.1 conda-forge::gawk=5.1.0"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
- 'https://depot.galaxyproject.org/singularity/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:1df389393721fc66f3fd8778ad938ac711951107-0' :
- 'biocontainers/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:1df389393721fc66f3fd8778ad938ac711951107-0' }"
+ 'https://depot.galaxyproject.org/singularity/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:019f262d90511939dce2dca4b7c868fc108f73db-0' :
+ 'biocontainers/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:019f262d90511939dce2dca4b7c868fc108f73db-0' }"
input:
tuple val(meta), path(fasta)
diff --git a/modules/nf-core/star/genomegenerate/meta.yml b/modules/nf-core/star/genomegenerate/meta.yml
index eba2d9cf..1061e1b8 100644
--- a/modules/nf-core/star/genomegenerate/meta.yml
+++ b/modules/nf-core/star/genomegenerate/meta.yml
@@ -31,7 +31,6 @@ input:
- gtf:
type: file
description: GTF file of the reference genome
-
output:
- meta:
type: map
@@ -46,7 +45,9 @@ output:
type: file
description: File containing software versions
pattern: "versions.yml"
-
authors:
- "@kevinmenden"
- "@drpatelh"
+maintainers:
+ - "@kevinmenden"
+ - "@drpatelh"
diff --git a/modules/nf-core/star/genomegenerate/tests/main.nf.test b/modules/nf-core/star/genomegenerate/tests/main.nf.test
new file mode 100644
index 00000000..eed82926
--- /dev/null
+++ b/modules/nf-core/star/genomegenerate/tests/main.nf.test
@@ -0,0 +1,38 @@
+nextflow_process {
+
+ name "Test Process STAR_GENOMEGENERATE"
+ script "../main.nf"
+ process "STAR_GENOMEGENERATE"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "star"
+ tag "star/genomegenerate"
+
+ test("homo_sapiens") {
+
+ when {
+ process {
+ """
+ input[0] = Channel.of([
+ [ id:'test_fasta' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)]
+ ])
+ input[1] = Channel.of([
+ [ id:'test_gtf' ],
+ [file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)]
+ ])
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(file(process.out.index[0][1]).name).match("index") },
+ { assert snapshot(process.out.versions).match("versions") }
+ )
+ }
+
+ }
+
+}
\ No newline at end of file
diff --git a/modules/nf-core/star/genomegenerate/tests/main.nf.test.snap b/modules/nf-core/star/genomegenerate/tests/main.nf.test.snap
new file mode 100644
index 00000000..bd4e0caa
--- /dev/null
+++ b/modules/nf-core/star/genomegenerate/tests/main.nf.test.snap
@@ -0,0 +1,16 @@
+{
+ "versions": {
+ "content": [
+ [
+ "versions.yml:md5,9c11319b80fdedc90dadce4e0fb42ded"
+ ]
+ ],
+ "timestamp": "2023-11-23T11:18:14.835118"
+ },
+ "index": {
+ "content": [
+ "star"
+ ],
+ "timestamp": "2023-11-23T11:31:47.560528"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/star/genomegenerate/tests/tags.yml b/modules/nf-core/star/genomegenerate/tests/tags.yml
new file mode 100644
index 00000000..79f619bf
--- /dev/null
+++ b/modules/nf-core/star/genomegenerate/tests/tags.yml
@@ -0,0 +1,2 @@
+star/genomegenerate:
+ - modules/nf-core/star/genomegenerate/**
diff --git a/modules/nf-core/stringtie/merge/environment.yml b/modules/nf-core/stringtie/merge/environment.yml
new file mode 100644
index 00000000..9914b202
--- /dev/null
+++ b/modules/nf-core/stringtie/merge/environment.yml
@@ -0,0 +1,7 @@
+name: stringtie_merge
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::stringtie=2.2.1
diff --git a/modules/nf-core/stringtie/merge/main.nf b/modules/nf-core/stringtie/merge/main.nf
index 12224f78..c2568219 100644
--- a/modules/nf-core/stringtie/merge/main.nf
+++ b/modules/nf-core/stringtie/merge/main.nf
@@ -2,7 +2,7 @@ process STRINGTIE_MERGE {
label 'process_medium'
// Note: 2.7X indices incompatible with AWS iGenomes.
- conda "bioconda::stringtie=2.2.1"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/stringtie:2.2.1--hecb563c_2' :
'biocontainers/stringtie:2.2.1--hecb563c_2' }"
diff --git a/modules/nf-core/stringtie/merge/meta.yml b/modules/nf-core/stringtie/merge/meta.yml
index 2e9784fe..5d02d678 100644
--- a/modules/nf-core/stringtie/merge/meta.yml
+++ b/modules/nf-core/stringtie/merge/meta.yml
@@ -32,6 +32,7 @@ output:
type: file
description: File containing software versions
pattern: "versions.yml"
-
authors:
- "@yuukiiwa"
+maintainers:
+ - "@yuukiiwa"
diff --git a/modules/nf-core/stringtie/merge/tests/main.nf.test b/modules/nf-core/stringtie/merge/tests/main.nf.test
new file mode 100644
index 00000000..90368134
--- /dev/null
+++ b/modules/nf-core/stringtie/merge/tests/main.nf.test
@@ -0,0 +1,82 @@
+nextflow_process {
+
+ name "Test Process STRINGTIE_MERGE"
+ script "../main.nf"
+ process "STRINGTIE_MERGE"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "stringtie"
+ tag "stringtie/merge"
+
+ test("homo_sapiens - forward strandedness") {
+
+ setup {
+ run("STRINGTIE_STRINGTIE") {
+ script "../../stringtie/main.nf"
+ process {
+ """
+ input[0] = [
+ [ id:'test', strandedness:'forward' ], // meta map
+ [ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true) ]
+ ]
+ input[1] = file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)
+ """
+ }
+ }
+
+ }
+
+ when {
+ process {
+ """
+ input[0] = STRINGTIE_STRINGTIE.out.transcript_gtf.map { it -> it[1] }
+ input[1] = file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.gtf).match("fs_gtf") },
+ { assert snapshot(process.out.versions).match("fs_versions") }
+ )
+ }
+ }
+
+ test("homo_sapiens - reverse strandedness") {
+
+ setup {
+ run("STRINGTIE_STRINGTIE") {
+ script "../../stringtie/main.nf"
+ process {
+ """
+ input[0] = [
+ [ id:'test', strandedness:'reverse' ], // meta map
+ [ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true) ]
+ ]
+ input[1] = file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)
+ """
+ }
+ }
+
+ }
+
+ when {
+ process {
+ """
+ input[0] = STRINGTIE_STRINGTIE.out.transcript_gtf.map { it -> it[1] }
+ input[1] = file(params.test_data['homo_sapiens']['genome']['genome_gtf'], checkIfExists: true)
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.gtf).match("rs_gtf") },
+ { assert snapshot(process.out.versions).match("rs_versions") }
+ )
+ }
+ }
+}
diff --git a/modules/nf-core/stringtie/merge/tests/main.nf.test.snap b/modules/nf-core/stringtie/merge/tests/main.nf.test.snap
new file mode 100644
index 00000000..3e4bc68f
--- /dev/null
+++ b/modules/nf-core/stringtie/merge/tests/main.nf.test.snap
@@ -0,0 +1,34 @@
+{
+ "rs_versions": {
+ "content": [
+ [
+ "versions.yml:md5,b73d45fdebf4c8c446bb01817db1665d"
+ ]
+ ],
+ "timestamp": "2023-11-23T14:14:39.697712988"
+ },
+ "rs_gtf": {
+ "content": [
+ [
+ "stringtie.merged.gtf:md5,6da479298d73d5b3216d4e1576a2bdf4"
+ ]
+ ],
+ "timestamp": "2023-11-23T14:14:39.691894799"
+ },
+ "fs_gtf": {
+ "content": [
+ [
+ "stringtie.merged.gtf:md5,d959eb2fab0db48ded7275e0a2e83c05"
+ ]
+ ],
+ "timestamp": "2023-11-23T14:14:20.872841278"
+ },
+ "fs_versions": {
+ "content": [
+ [
+ "versions.yml:md5,b73d45fdebf4c8c446bb01817db1665d"
+ ]
+ ],
+ "timestamp": "2023-11-23T14:14:20.883140097"
+ }
+}
\ No newline at end of file
diff --git a/modules/nf-core/stringtie/merge/tests/tags.yml b/modules/nf-core/stringtie/merge/tests/tags.yml
new file mode 100644
index 00000000..58cef46b
--- /dev/null
+++ b/modules/nf-core/stringtie/merge/tests/tags.yml
@@ -0,0 +1,2 @@
+stringtie/merge:
+ - modules/nf-core/stringtie/merge/**
diff --git a/modules/nf-core/stringtie/stringtie/environment.yml b/modules/nf-core/stringtie/stringtie/environment.yml
new file mode 100644
index 00000000..7a0eccdb
--- /dev/null
+++ b/modules/nf-core/stringtie/stringtie/environment.yml
@@ -0,0 +1,7 @@
+name: stringtie_stringtie
+channels:
+ - conda-forge
+ - bioconda
+ - defaults
+dependencies:
+ - bioconda::stringtie=2.2.1
diff --git a/modules/nf-core/stringtie/stringtie/main.nf b/modules/nf-core/stringtie/stringtie/main.nf
index d0f8b563..6e25ba27 100644
--- a/modules/nf-core/stringtie/stringtie/main.nf
+++ b/modules/nf-core/stringtie/stringtie/main.nf
@@ -2,7 +2,7 @@ process STRINGTIE_STRINGTIE {
tag "$meta.id"
label 'process_medium'
- conda "bioconda::stringtie=2.2.1"
+ conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/stringtie:2.2.1--hecb563c_2' :
'biocontainers/stringtie:2.2.1--hecb563c_2' }"
diff --git a/modules/nf-core/stringtie/stringtie/meta.yml b/modules/nf-core/stringtie/stringtie/meta.yml
index 75518470..d8ebdd88 100644
--- a/modules/nf-core/stringtie/stringtie/meta.yml
+++ b/modules/nf-core/stringtie/stringtie/meta.yml
@@ -5,7 +5,6 @@ keywords:
- assembly
- quantification
- gtf
-
tools:
- stringtie2:
description: |
@@ -55,3 +54,5 @@ output:
pattern: "versions.yml"
authors:
- "@drpatelh"
+maintainers:
+ - "@drpatelh"
diff --git a/modules/nf-core/stringtie/stringtie/tests/main.nf.test b/modules/nf-core/stringtie/stringtie/tests/main.nf.test
new file mode 100644
index 00000000..68786b74
--- /dev/null
+++ b/modules/nf-core/stringtie/stringtie/tests/main.nf.test
@@ -0,0 +1,108 @@
+nextflow_process {
+
+ name "Test Process STRINGTIE_STRINGTIE"
+ script "../main.nf"
+ process "STRINGTIE_STRINGTIE"
+ tag "modules"
+ tag "modules_nfcore"
+ tag "stringtie"
+ tag "stringtie/stringtie"
+
+ test("sarscov2 [bam] - forward strandedness") {
+
+ when {
+ process {
+ """
+ input[0] = [
+ [ id:'test', strandedness:'forward' ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true) ]
+ ]
+ input[1] = []
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.transcript_gtf).match("fs_transcript_gtf") },
+ { assert snapshot(process.out.abundance).match("fs_abundance") },
+ { assert snapshot(process.out.versions).match("fs_versions") }
+ )
+ }
+ }
+
+ test("sarscov2 [bam] - forward strandedness + reference annotation") {
+
+ when {
+ process {
+ """
+ input[0] = [
+ [ id:'test', strandedness:'forward' ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true) ]
+ ]
+ input[1] = file(params.test_data['sarscov2']['genome']['genome_gtf'], checkIfExists: true)
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.transcript_gtf).match("fs_gtf_transcript_gtf") },
+ { assert snapshot(process.out.abundance).match("fs_gtf_abundance") },
+ { assert snapshot(process.out.ballgown).match("fs_gtf_ballgown") },
+ { assert snapshot(process.out.versions).match("fs_gtf_versions") }
+ )
+ }
+ }
+
+ test("sarscov2 [bam] - reverse strandedness") {
+
+ when {
+ process {
+ """
+ input[0] = [
+ [ id:'test', strandedness:'reverse' ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true) ]
+ ]
+ input[1] = []
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.transcript_gtf).match("rs_transcript_gtf") },
+ { assert snapshot(process.out.abundance).match("rs_abundance") },
+ { assert snapshot(process.out.versions).match("rs_versions") }
+ )
+ }
+ }
+
+ test("sarscov2 [bam] - reverse strandedness + reference annotation") {
+
+ when {
+ process {
+ """
+ input[0] = [
+ [ id:'test', strandedness:'reverse' ], // meta map
+ [ file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true) ]
+ ]
+ input[1] = file(params.test_data['sarscov2']['genome']['genome_gtf'], checkIfExists: true)
+ """
+ }
+ }
+
+ then {
+ assertAll(
+ { assert process.success },
+ { assert snapshot(process.out.transcript_gtf).match("rs_gtf_transcript_gtf") },
+ { assert snapshot(process.out.abundance).match("rs_gtf_abundance") },
+ { assert snapshot(process.out.ballgown).match("rs_gtf_ballgown") },
+ { assert snapshot(process.out.versions).match("rs_gtf_versions") }
+ )
+ }
+ }
+}
diff --git a/modules/nf-core/stringtie/stringtie/tests/main.nf.test.snap b/modules/nf-core/stringtie/stringtie/tests/main.nf.test.snap
new file mode 100644
index 00000000..bf751636
--- /dev/null
+++ b/modules/nf-core/stringtie/stringtie/tests/main.nf.test.snap
@@ -0,0 +1,186 @@
+{
+ "fs_abundance": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "forward"
+ },
+ "test.gene.abundance.txt:md5,d6f5c8cadb8458f1df0427cf790246e3"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:55:41.032044613"
+ },
+ "fs_transcript_gtf": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "forward"
+ },
+ "test.transcripts.gtf:md5,569137af5be452413086b50653a97203"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:55:41.017978904"
+ },
+ "rs_abundance": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "reverse"
+ },
+ "test.gene.abundance.txt:md5,d6f5c8cadb8458f1df0427cf790246e3"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:13.601112933"
+ },
+ "fs_gtf_versions": {
+ "content": [
+ [
+ "versions.yml:md5,3410e8ac349d18c85ddee89337851d38"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:00.523797974"
+ },
+ "fs_gtf_transcript_gtf": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "forward"
+ },
+ "test.transcripts.gtf:md5,f56cf8aba2c4a5673bc7963ba5f12d04"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:00.475164879"
+ },
+ "rs_versions": {
+ "content": [
+ [
+ "versions.yml:md5,3410e8ac349d18c85ddee89337851d38"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:13.623892691"
+ },
+ "rs_gtf_transcript_gtf": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "reverse"
+ },
+ "test.transcripts.gtf:md5,bb346053a8c156b803b055133376c7fa"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:22.693599559"
+ },
+ "fs_gtf_abundance": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "forward"
+ },
+ "test.gene.abundance.txt:md5,7d8bce7f2a922e367cedccae7267c22e"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:00.482135418"
+ },
+ "rs_gtf_ballgown": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "reverse"
+ },
+ [
+ "e2t.ctab:md5,e981c0038295ae54b63cedb1083f1540",
+ "e_data.ctab:md5,879b6696029d19c4737b562e9d149218",
+ "i2t.ctab:md5,8a117c8aa4334b4c2d4711932b006fb4",
+ "i_data.ctab:md5,be3abe09740603213f83d50dcf81427f",
+ "t_data.ctab:md5,3b66c065da73ae0dd41cc332eff6a818"
+ ]
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:22.715698347"
+ },
+ "rs_transcript_gtf": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "reverse"
+ },
+ "test.transcripts.gtf:md5,31c34aec2bf36bb0ea3c16c2afeeeb1f"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:13.590054035"
+ },
+ "rs_gtf_versions": {
+ "content": [
+ [
+ "versions.yml:md5,3410e8ac349d18c85ddee89337851d38"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:22.725513476"
+ },
+ "fs_gtf_ballgown": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "forward"
+ },
+ [
+ "e2t.ctab:md5,e981c0038295ae54b63cedb1083f1540",
+ "e_data.ctab:md5,6b4cf69bc03f3f69890f972a0e8b7471",
+ "i2t.ctab:md5,8a117c8aa4334b4c2d4711932b006fb4",
+ "i_data.ctab:md5,be3abe09740603213f83d50dcf81427f",
+ "t_data.ctab:md5,3b66c065da73ae0dd41cc332eff6a818"
+ ]
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:00.494299817"
+ },
+ "fs_versions": {
+ "content": [
+ [
+ "versions.yml:md5,3410e8ac349d18c85ddee89337851d38"
+ ]
+ ],
+ "timestamp": "2023-11-23T13:55:41.049417582"
+ },
+ "rs_gtf_abundance": {
+ "content": [
+ [
+ [
+ {
+ "id": "test",
+ "strandedness": "reverse"
+ },
+ "test.gene.abundance.txt:md5,7385b870b955dae2c2ab78a70cf05cce"
+ ]
+ ]
+ ],
+ "timestamp": "2023-11-23T13:56:22.701059059"
+ }
+}
diff --git a/modules/nf-core/stringtie/stringtie/tests/tags.yml b/modules/nf-core/stringtie/stringtie/tests/tags.yml
new file mode 100644
index 00000000..da9b051c
--- /dev/null
+++ b/modules/nf-core/stringtie/stringtie/tests/tags.yml
@@ -0,0 +1,2 @@
+stringtie/stringtie:
+ - modules/nf-core/stringtie/stringtie/**
diff --git a/nextflow.config b/nextflow.config
index 994e96e3..7570a93b 100644
--- a/nextflow.config
+++ b/nextflow.config
@@ -32,11 +32,9 @@ params {
starfusion_build = true
// Filtering
- fusioninspector_filter = false
- fusionreport_filter = true
+ tools_cutoff = 1
// Trimming
- trim = false
fastp_trim = false
trim_tail = null
adapter_fasta = []
@@ -55,8 +53,6 @@ params {
all = false
arriba = false
fusioncatcher = false
- pizzly = false
- squid = false
starindex = false
starfusion = false
stringtie = false
@@ -70,13 +66,13 @@ params {
// Path to references
ensembl_ref = "${params.genomes_base}/ensembl"
arriba_ref = "${params.genomes_base}/arriba"
- arriba_ref_blacklist = "${params.genomes_base}/arriba/blacklist_hg38_GRCh38_v2.3.0.tsv.gz"
- arriba_ref_cytobands = "${params.genomes_base}/arriba/cytobands_hg38_GRCh38_v2.3.0.tsv"
- arriba_ref_known_fusions = "${params.genomes_base}/arriba/known_fusions_hg38_GRCh38_v2.3.0.tsv.gz"
- arriba_ref_protein_domains = "${params.genomes_base}/arriba/protein_domains_hg38_GRCh38_v2.3.0.gff3"
+ arriba_ref_blacklist = "${params.genomes_base}/arriba/blacklist_hg38_GRCh38_v2.4.0.tsv.gz"
+ arriba_ref_cytobands = "${params.genomes_base}/arriba/cytobands_hg38_GRCh38_v2.4.0.tsv"
+ arriba_ref_known_fusions = "${params.genomes_base}/arriba/known_fusions_hg38_GRCh38_v2.4.0.tsv.gz"
+ arriba_ref_protein_domains = "${params.genomes_base}/arriba/protein_domains_hg38_GRCh38_v2.4.0.gff3"
fusioncatcher_ref = "${params.genomes_base}/fusioncatcher/human_v102"
- pizzly_ref = "${params.genomes_base}/pizzly/kallisto"
- squid_ref = "${params.genomes_base}/squid"
+ hgnc_ref = "${params.genomes_base}/hgnc/hgnc_complete_set.txt"
+ hgnc_date = "${params.genomes_base}/hgnc/HGNC-DB-timestamp.txt"
starfusion_ref = "${params.genomes_base}/starfusion/ctat_genome_lib_build_dir"
starindex_ref = "${params.genomes_base}/star"
fusionreport_ref = "${params.genomes_base}/fusion_report_db"
@@ -84,8 +80,6 @@ params {
// Path to fusion outputs
arriba_fusions = null
- pizzly_fusions = null
- squid_fusions = null
starfusion_fusions = null
fusioncatcher_fusions = null
fusioninspector_fusions = null
@@ -222,6 +216,7 @@ profiles {
}
apptainer {
apptainer.enabled = true
+ apptainer.autoMounts = true
conda.enabled = false
docker.enabled = false
singularity.enabled = false
@@ -238,8 +233,8 @@ profiles {
gitpod {
executor.name = 'local'
- executor.cpus = 16
- executor.memory = 60.GB
+ executor.cpus = 4
+ executor.memory = 8.GB
}
}
@@ -295,7 +290,7 @@ manifest {
description = """Nextflow rnafusion analysis pipeline, part of the nf-core community."""
mainScript = 'main.nf'
nextflowVersion = '!>=23.04.0'
- version = '2.4.0'
+ version = '3.0.0'
doi = ''
}
diff --git a/nextflow_schema.json b/nextflow_schema.json
index 02cd1e27..29ae6288 100644
--- a/nextflow_schema.json
+++ b/nextflow_schema.json
@@ -32,7 +32,6 @@
"input": {
"type": "string",
"format": "file-path",
- "exists": true,
"mimetype": "text/csv",
"pattern": "^\\S+\\.csv$",
"description": "Path to comma-separated file containing information about the samples in the experiment.",
@@ -62,6 +61,16 @@
"fa_icon": "far fa-file-code",
"description": "Specifies which analysis type for the pipeline - either build references or analyse data"
},
+ "cosmic_username": {
+ "type": "string",
+ "fa_icon": "far fa-file-code",
+ "description": "COSMIC username"
+ },
+ "cosmic_passwd": {
+ "type": "string",
+ "fa_icon": "far fa-file-code",
+ "description": "COSMIC password"
+ },
"genomes_base": {
"type": "string",
"fa_icon": "far fa-file-code",
@@ -149,11 +158,6 @@
"fa_icon": "far fa-file-code",
"description": "Path to fusioncatcher references"
},
- "fusioninspector_filter": {
- "type": "boolean",
- "fa_icon": "far fa-file-code",
- "description": "Feed filtered fusionreport fusions to fusioninspector"
- },
"fusioninspector_limitSjdbInsertNsj": {
"type": "integer",
"fa_icon": "far fa-file-code",
@@ -179,41 +183,20 @@
"fa_icon": "far fa-file-code",
"description": "Path to fusionreport references"
},
- "fusionreport_filter": {
- "type": "boolean",
- "fa_icon": "far fa-file-code",
- "default": true,
- "description": "Display fusions identified with 2 tools or more"
- },
- "pizzly": {
- "type": "boolean",
- "fa_icon": "far fa-file-code",
- "description": "Build or run pizzly references/analyses"
- },
- "pizzly_fusions": {
+ "hgnc_ref": {
"type": "string",
"fa_icon": "far fa-file-code",
- "description": "Path to pizzly output"
+ "description": "Path to HGNC database file"
},
- "pizzly_ref": {
+ "hgnc_date": {
"type": "string",
"fa_icon": "far fa-file-code",
- "description": "Path to pizzly references"
+ "description": "Path to HGNC timestamp file for database retrieval"
},
- "squid": {
+ "qiagen": {
"type": "boolean",
"fa_icon": "far fa-file-code",
- "description": "Build or run squid references/analyses"
- },
- "squid_fusions": {
- "type": "string",
- "fa_icon": "far fa-file-code",
- "description": "Path to squid output"
- },
- "squid_ref": {
- "type": "string",
- "fa_icon": "far fa-file-code",
- "description": "Path to squid references"
+ "description": "Use QIAGEN instead of SANGER to download COSMIC database"
},
"starfusion": {
"type": "boolean",
@@ -245,25 +228,15 @@
"fa_icon": "far fa-file-code",
"description": "Run stringtie analysis"
},
- "whitelist": {
- "type": "string",
- "fa_icon": "far fa-file-code",
- "description": "Path to fusions to add to the input of fusioninspector"
- },
- "cosmic_username": {
- "type": "string",
+ "tools_cutoff": {
+ "type": "integer",
"fa_icon": "far fa-file-code",
- "description": "COSMIC username"
+ "description": "Discard fusions identified by less than INT tools"
},
- "cosmic_passwd": {
+ "whitelist": {
"type": "string",
"fa_icon": "far fa-file-code",
- "description": "COSMIC password"
- },
- "qiagen": {
- "type": "boolean",
- "fa_icon": "far fa-file-code",
- "description": "Use QIAGEN instead of SANGER to download COSMIC database"
+ "description": "Path to fusions to add to the input of fusioninspector"
}
}
},
@@ -273,11 +246,6 @@
"fa_icon": "fas fa-cut",
"description": "Options to adjust read trimming criteria.",
"properties": {
- "trim": {
- "type": "boolean",
- "description": "Preform trimming of reads, default: false",
- "fa_icon": "fas fa-cut"
- },
"fastp_trim": {
"type": "boolean",
"description": "Preform fastp trimming of reads, default: false",
@@ -303,7 +271,7 @@
"properties": {
"cram": {
"type": "string",
- "description": "List of tools for which to compress BAM file to CRAM,default: [], options: arriba, squid, starfusion. Leave no space between options",
+ "description": "List of tools for which to compress BAM file to CRAM,default: [], options: arriba, starfusion. Leave no space between options",
"fa_icon": "fas fa-cut"
}
}
@@ -471,14 +439,12 @@
"type": "boolean",
"description": "Display help text.",
"fa_icon": "fas fa-question-circle",
- "default": false,
"hidden": true
},
"version": {
"type": "boolean",
"description": "Display version and exit.",
"fa_icon": "fas fa-question-circle",
- "default": false,
"hidden": true
},
"publish_dir_mode": {
@@ -502,7 +468,6 @@
"type": "boolean",
"description": "Send plain-text email instead of HTML.",
"fa_icon": "fas fa-remove-format",
- "default": false,
"hidden": true
},
"max_multiqc_email_size": {
@@ -517,7 +482,6 @@
"type": "boolean",
"description": "Do not use coloured log outputs.",
"fa_icon": "fas fa-palette",
- "default": false,
"hidden": true
},
"hook_url": {
@@ -556,7 +520,6 @@
"type": "boolean",
"fa_icon": "far fa-eye-slash",
"description": "Show all params when using `--help`",
- "default": false,
"hidden": true,
"help_text": "By default, parameters set as _hidden_ in the schema are not shown on the command line when a user runs with `--help`. Specifying this option will tell the pipeline to show all parameters."
},
@@ -564,7 +527,6 @@
"type": "boolean",
"fa_icon": "far fa-check-circle",
"description": "Validation of parameters fails when an unrecognised parameter is found.",
- "default": false,
"hidden": true,
"help_text": "By default, when an unrecognised parameter is found, it returns a warinig."
},
@@ -572,7 +534,6 @@
"type": "boolean",
"fa_icon": "far fa-check-circle",
"description": "Validation of parameters in lenient more.",
- "default": false,
"hidden": true,
"help_text": "Allows string values that are parseable as numbers or booleans. For further information see [JSONSchema docs](https://github.com/everit-org/json-schema#lenient-mode)."
},
diff --git a/subworkflows/local/arriba_workflow.nf b/subworkflows/local/arriba_workflow.nf
index 36c3924f..3aa9c090 100644
--- a/subworkflows/local/arriba_workflow.nf
+++ b/subworkflows/local/arriba_workflow.nf
@@ -1,4 +1,6 @@
include { ARRIBA } from '../../modules/nf-core/arriba/main'
+include { SAMTOOLS_INDEX as SAMTOOLS_INDEX_FOR_ARRIBA} from '../../modules/nf-core/samtools/index/main'
+include { SAMTOOLS_SORT as SAMTOOLS_SORT_FOR_ARRIBA} from '../../modules/nf-core/samtools/sort/main'
include { SAMTOOLS_VIEW as SAMTOOLS_VIEW_FOR_ARRIBA} from '../../modules/nf-core/samtools/view/main'
include { STAR_ALIGN as STAR_FOR_ARRIBA } from '../../modules/nf-core/star/align/main'
@@ -35,11 +37,16 @@ workflow ARRIBA_WORKFLOW {
if (params.cram.contains('arriba') ){
- SAMTOOLS_VIEW_FOR_ARRIBA(STAR_FOR_ARRIBA.out.bam.map { meta, bam -> [ meta, bam, [] ] }, ch_fasta, [])
+ SAMTOOLS_SORT_FOR_ARRIBA(STAR_FOR_ARRIBA.out.bam)
+ ch_versions = ch_versions.mix(SAMTOOLS_SORT_FOR_ARRIBA.out.versions )
+
+ SAMTOOLS_VIEW_FOR_ARRIBA(SAMTOOLS_SORT_FOR_ARRIBA.out.bam.map { meta, bam -> [ meta, bam, [] ] }, ch_fasta, [])
ch_versions = ch_versions.mix(SAMTOOLS_VIEW_FOR_ARRIBA.out.versions )
- }
+ SAMTOOLS_INDEX_FOR_ARRIBA(SAMTOOLS_VIEW_FOR_ARRIBA.out.cram)
+ ch_versions = ch_versions.mix(SAMTOOLS_INDEX_FOR_ARRIBA.out.versions )
+ }
}
else {
diff --git a/subworkflows/local/fusioninspector_workflow.nf b/subworkflows/local/fusioninspector_workflow.nf
index 5fa21cf1..48fcc19f 100644
--- a/subworkflows/local/fusioninspector_workflow.nf
+++ b/subworkflows/local/fusioninspector_workflow.nf
@@ -1,6 +1,7 @@
+include { AGAT_CONVERTSPGFF2TSV } from '../../modules/nf-core/agat/convertspgff2tsv/main'
include { ARRIBA_VISUALISATION } from '../../modules/local/arriba/visualisation/main'
include { CAT_CAT } from '../../modules/nf-core/cat/cat/main'
-include { MEGAFUSION } from '../../modules/local/megafusion/main'
+include { VCF_COLLECT } from '../../modules/local/vcf_collect/main'
include { FUSIONINSPECTOR } from '../../modules/local/fusioninspector/main'
workflow FUSIONINSPECTOR_WORKFLOW {
@@ -8,16 +9,21 @@ workflow FUSIONINSPECTOR_WORKFLOW {
reads
fusion_list
fusion_list_filtered
- report
+ fusionreport_out
+ fusionreport_csv
bam_sorted_indexed
ch_gtf
ch_arriba_ref_protein_domains
ch_arriba_ref_cytobands
+ ch_hgnc_ref
+ ch_hgnc_date
main:
ch_versions = Channel.empty()
+ ch_arriba_visualisation = Channel.empty()
index ="${params.starfusion_ref}"
- ch_fusion_list = ( params.fusioninspector_filter ? fusion_list_filtered : fusion_list )
+
+ ch_fusion_list = ( params.tools_cutoff > 1 ? fusion_list_filtered : fusion_list )
.branch{
no_fusions: it[1].size() == 0
fusions: it[1].size() > 0
@@ -33,22 +39,27 @@ workflow FUSIONINSPECTOR_WORKFLOW {
ch_fusion_list.fusions = CAT_CAT.out.file_out
}
- reads_fusion = reads.join(ch_fusion_list.fusions )
+ ch_reads_fusion = reads.join(ch_fusion_list.fusions )
- FUSIONINSPECTOR( reads_fusion, index)
+ FUSIONINSPECTOR( ch_reads_fusion, index)
ch_versions = ch_versions.mix(FUSIONINSPECTOR.out.versions)
- fusion_data = FUSIONINSPECTOR.out.tsv.join(report)
- MEGAFUSION(fusion_data)
- ch_versions = ch_versions.mix(MEGAFUSION.out.versions)
+ AGAT_CONVERTSPGFF2TSV(FUSIONINSPECTOR.out.out_gtf)
+ ch_versions = ch_versions.mix(AGAT_CONVERTSPGFF2TSV.out.versions)
+
+ fusion_data = FUSIONINSPECTOR.out.tsv_coding_effect.join(AGAT_CONVERTSPGFF2TSV.out.tsv).join(fusionreport_out).join(fusionreport_csv)
+ VCF_COLLECT(fusion_data, ch_hgnc_ref, ch_hgnc_date)
+ ch_versions = ch_versions.mix(VCF_COLLECT.out.versions)
if ((params.starfusion || params.all || params.stringtie) && !params.fusioninspector_only && !params.skip_vis) {
- bam_sorted_indexed_fusions = bam_sorted_indexed.join(FUSIONINSPECTOR.out.tsv)
- ARRIBA_VISUALISATION(bam_sorted_indexed_fusions, ch_gtf, ch_arriba_ref_protein_domains, ch_arriba_ref_cytobands)
+ ch_bam_sorted_indexed_fusions = bam_sorted_indexed.join(FUSIONINSPECTOR.out.tsv)
+ ARRIBA_VISUALISATION(ch_bam_sorted_indexed_fusions, ch_gtf, ch_arriba_ref_protein_domains, ch_arriba_ref_cytobands)
ch_versions = ch_versions.mix(ARRIBA_VISUALISATION.out.versions)
+ ch_arriba_visualisation = ARRIBA_VISUALISATION.out.pdf
}
emit:
- versions = ch_versions.ifEmpty(null)
+ ch_arriba_visualisation
+ versions = ch_versions.ifEmpty(null)
}
diff --git a/subworkflows/local/fusionreport_workflow.nf b/subworkflows/local/fusionreport_workflow.nf
index 478986a4..632ba2a3 100644
--- a/subworkflows/local/fusionreport_workflow.nf
+++ b/subworkflows/local/fusionreport_workflow.nf
@@ -6,28 +6,26 @@ workflow FUSIONREPORT_WORKFLOW {
reads
fusionreport_ref
arriba_fusions
- pizzly_fusions
- squid_fusions
starfusion_fusions
fusioncatcher_fusions
main:
ch_versions = Channel.empty()
ch_report = Channel.empty()
+ ch_csv = Channel.empty()
if (!params.fusioninspector_only) {
reads_fusions = reads
.join(arriba_fusions, remainder: true)
- .join(pizzly_fusions, remainder: true)
- .join(squid_fusions, remainder: true)
.join(starfusion_fusions, remainder: true)
.join(fusioncatcher_fusions, remainder: true)
- FUSIONREPORT(reads_fusions, fusionreport_ref)
+ FUSIONREPORT(reads_fusions, fusionreport_ref, params.tools_cutoff)
ch_fusion_list = FUSIONREPORT.out.fusion_list
ch_fusion_list_filtered = FUSIONREPORT.out.fusion_list_filtered
ch_versions = ch_versions.mix(FUSIONREPORT.out.versions)
ch_report = FUSIONREPORT.out.report
+ ch_csv = FUSIONREPORT.out.csv
} else {
ch_fusion_list = reads.combine(Channel.value(file(params.fusioninspector_fusions, checkIfExists:true)))
.map { meta, reads, fusions -> [ meta, fusions ] }
@@ -39,6 +37,8 @@ workflow FUSIONREPORT_WORKFLOW {
versions = ch_versions.ifEmpty(null)
fusion_list = ch_fusion_list
fusion_list_filtered = ch_fusion_list_filtered
- report = ch_report.ifEmpty(null)
+ report = ch_report.ifEmpty(null)
+ csv = ch_csv.ifEmpty(null)
+
}
diff --git a/subworkflows/local/pizzly_workflow.nf b/subworkflows/local/pizzly_workflow.nf
deleted file mode 100644
index 7675432b..00000000
--- a/subworkflows/local/pizzly_workflow.nf
+++ /dev/null
@@ -1,37 +0,0 @@
-include { KALLISTO_QUANT } from '../../modules/local/kallisto/quant/main'
-include { PIZZLY } from '../../modules/local/pizzly/detect/main'
-
-workflow PIZZLY_WORKFLOW {
- take:
- reads
- ch_gtf
- ch_transcript
-
- main:
- ch_versions = Channel.empty()
- ch_dummy_file = file("$baseDir/assets/dummy_file_pizzly.txt", checkIfExists: true)
-
- if ((params.pizzly || params.all) && !params.fusioninspector_only) {
- if (params.pizzly_fusions) {
- ch_pizzly_fusions = reads.combine(Channel.value(file(params.pizzly_fusions, checkIfExists:true)))
- .map { meta, reads, fusions -> [ meta, fusions ] }
- } else {
- KALLISTO_QUANT(reads, params.pizzly_ref )
- ch_versions = ch_versions.mix(KALLISTO_QUANT.out.versions)
-
- PIZZLY( KALLISTO_QUANT.out.txt, ch_transcript, ch_gtf )
- ch_versions = ch_versions.mix(PIZZLY.out.versions)
-
- ch_pizzly_fusions = PIZZLY.out.fusions
- }
- }
- else {
- ch_pizzly_fusions = reads.combine(Channel.value(file(ch_dummy_file, checkIfExists:true)))
- .map { meta, reads, fusions -> [ meta, fusions ] }
- }
-
- emit:
- fusions = ch_pizzly_fusions
- versions = ch_versions.ifEmpty(null)
- }
-
diff --git a/subworkflows/local/qc_workflow.nf b/subworkflows/local/qc_workflow.nf
index bdf887d1..576701e5 100644
--- a/subworkflows/local/qc_workflow.nf
+++ b/subworkflows/local/qc_workflow.nf
@@ -2,9 +2,9 @@
// Check input samplesheet and get read channels
//
-include { QUALIMAP_RNASEQ } from '../../modules/nf-core/qualimap/rnaseq/main'
include { PICARD_COLLECTRNASEQMETRICS } from '../../modules/local/picard/collectrnaseqmetrics/main'
-include { PICARD_MARKDUPLICATES } from '../../modules/nf-core/picard/markduplicates/main'
+include { GATK4_MARKDUPLICATES } from '../../modules/nf-core/gatk4/markduplicates/main'
+include { PICARD_COLLECTINSERTSIZEMETRICS } from '../../modules/nf-core/picard/collectinsertsizemetrics/main'
workflow QC_WORKFLOW {
take:
@@ -19,24 +19,24 @@ workflow QC_WORKFLOW {
main:
ch_versions = Channel.empty()
- QUALIMAP_RNASEQ(ch_bam_sorted, ch_chrgtf)
- ch_versions = ch_versions.mix(QUALIMAP_RNASEQ.out.versions)
- ch_qualimap_qc = Channel.empty().mix(QUALIMAP_RNASEQ.out.results)
-
PICARD_COLLECTRNASEQMETRICS(ch_bam_sorted_indexed, ch_refflat, ch_rrna_interval)
ch_versions = ch_versions.mix(PICARD_COLLECTRNASEQMETRICS.out.versions)
ch_rnaseq_metrics = Channel.empty().mix(PICARD_COLLECTRNASEQMETRICS.out.metrics)
- PICARD_MARKDUPLICATES(ch_bam_sorted, ch_fasta, ch_fai)
- ch_versions = ch_versions.mix(PICARD_MARKDUPLICATES.out.versions)
- ch_duplicate_metrics = Channel.empty().mix(PICARD_MARKDUPLICATES.out.metrics)
+ GATK4_MARKDUPLICATES(ch_bam_sorted, ch_fasta.map { meta, fasta -> [ fasta ]}, ch_fai.map { meta, fasta_fai -> [ fasta_fai ]})
+ ch_versions = ch_versions.mix(GATK4_MARKDUPLICATES.out.versions)
+ ch_duplicate_metrics = Channel.empty().mix(GATK4_MARKDUPLICATES.out.metrics)
+
+ PICARD_COLLECTINSERTSIZEMETRICS(ch_bam_sorted)
+ ch_versions = ch_versions.mix(PICARD_COLLECTINSERTSIZEMETRICS.out.versions)
+ ch_insertsize_metrics = Channel.empty().mix(PICARD_COLLECTINSERTSIZEMETRICS.out.metrics)
emit:
versions = ch_versions.ifEmpty(null)
- qualimap_qc = ch_qualimap_qc
rnaseq_metrics = ch_rnaseq_metrics
duplicate_metrics = ch_duplicate_metrics
+ insertsize_metrics = ch_insertsize_metrics
}
diff --git a/subworkflows/local/squid_workflow.nf b/subworkflows/local/squid_workflow.nf
deleted file mode 100644
index c4f29425..00000000
--- a/subworkflows/local/squid_workflow.nf
+++ /dev/null
@@ -1,80 +0,0 @@
-include { SAMTOOLS_INDEX as SAMTOOLS_INDEX_FOR_SQUID } from '../../modules/nf-core/samtools/index/main'
-include { SAMTOOLS_INDEX as SAMTOOLS_INDEX_FOR_SQUID_CHIMERIC } from '../../modules/nf-core/samtools/index/main'
-include { SAMTOOLS_SORT as SAMTOOLS_SORT_FOR_SQUID_CHIMERIC } from '../../modules/nf-core/samtools/sort/main'
-include { SAMTOOLS_VIEW as SAMTOOLS_VIEW_FOR_SQUID_CHIMERIC } from '../../modules/nf-core/samtools/view/main'
-include { SAMTOOLS_VIEW as SAMTOOLS_VIEW_FOR_SQUID_CRAM } from '../../modules/nf-core/samtools/view/main'
-include { SAMTOOLS_VIEW as SAMTOOLS_VIEW_FOR_SQUID_CRAM_CHIMERIC } from '../../modules/nf-core/samtools/view/main'
-include { SQUID } from '../../modules/local/squid/detect/main'
-include { SQUID_ANNOTATE } from '../../modules/local/squid/annotate/main'
-include { STAR_ALIGN as STAR_FOR_SQUID } from '../../modules/nf-core/star/align/main'
-
-workflow SQUID_WORKFLOW {
-
- take:
- reads
- ch_gtf
- ch_starindex_ensembl_ref
- ch_fasta
-
- main:
- ch_versions = Channel.empty()
- ch_dummy_file = file("$baseDir/assets/dummy_file_squid.txt", checkIfExists: true)
-
- if ((params.squid || params.all) && !params.fusioninspector_only) {
- if (params.squid_fusions){
- ch_squid_fusions = reads.combine(Channel.value(file(params.squid_fusions, checkIfExists:true)))
- .map { meta, reads, fusions -> [ meta, fusions ] }
- } else {
-
- STAR_FOR_SQUID(reads, ch_starindex_ensembl_ref, ch_gtf, params.star_ignore_sjdbgtf, '', params.seq_center ?: '')
- ch_versions = ch_versions.mix(STAR_FOR_SQUID.out.versions)
-
- STAR_FOR_SQUID.out.sam
- .map { meta, sam ->
- return [meta, sam, []]
- }.set { chimeric_sam }
-
-
-
- SAMTOOLS_VIEW_FOR_SQUID_CHIMERIC (chimeric_sam, ch_fasta, [])
- ch_versions = ch_versions.mix(SAMTOOLS_VIEW_FOR_SQUID_CHIMERIC.out.versions)
-
- SAMTOOLS_SORT_FOR_SQUID_CHIMERIC (SAMTOOLS_VIEW_FOR_SQUID_CHIMERIC.out.bam)
- ch_versions = ch_versions.mix(SAMTOOLS_SORT_FOR_SQUID_CHIMERIC.out.versions)
-
- bam_chimeric = STAR_FOR_SQUID.out.bam_sorted.join(SAMTOOLS_SORT_FOR_SQUID_CHIMERIC.out.bam)
-
- if (params.cram.contains('squid')){
- SAMTOOLS_INDEX_FOR_SQUID(STAR_FOR_SQUID.out.bam_sorted)
- ch_versions = ch_versions.mix(SAMTOOLS_INDEX_FOR_SQUID.out.versions)
- SAMTOOLS_INDEX_FOR_SQUID_CHIMERIC(SAMTOOLS_SORT_FOR_SQUID_CHIMERIC.out.bam)
- ch_versions = ch_versions.mix(SAMTOOLS_INDEX_FOR_SQUID_CHIMERIC.out.versions)
-
- bam_sorted_indexed = STAR_FOR_SQUID.out.bam_sorted.join(SAMTOOLS_INDEX_FOR_SQUID.out.bai)
- chimeric_sorted_indexed = SAMTOOLS_SORT_FOR_SQUID_CHIMERIC.out.bam.join(SAMTOOLS_INDEX_FOR_SQUID_CHIMERIC.out.bai)
-
- SAMTOOLS_VIEW_FOR_SQUID_CRAM (bam_sorted_indexed, ch_fasta, [])
- ch_versions = ch_versions.mix(SAMTOOLS_VIEW_FOR_SQUID_CRAM.out.versions)
- SAMTOOLS_VIEW_FOR_SQUID_CRAM_CHIMERIC (chimeric_sorted_indexed, ch_fasta, [])
- ch_versions = ch_versions.mix(SAMTOOLS_VIEW_FOR_SQUID_CRAM.out.versions)
- }
-
- SQUID (bam_chimeric)
- ch_versions = ch_versions.mix(SQUID.out.versions)
-
- SQUID_ANNOTATE (SQUID.out.fusions, ch_gtf)
- ch_versions = ch_versions.mix(SQUID_ANNOTATE.out.versions)
-
- ch_squid_fusions = SQUID_ANNOTATE.out.fusions_annotated
- }
- }
- else {
- ch_squid_fusions = reads.combine(Channel.value(file(ch_dummy_file, checkIfExists:true)))
- .map { meta, reads, fusions -> [ meta, fusions ] }
- }
-
- emit:
- fusions = ch_squid_fusions
- versions = ch_versions.ifEmpty(null)
- }
-
diff --git a/subworkflows/local/starfusion_workflow.nf b/subworkflows/local/starfusion_workflow.nf
index c9ba4bf3..38264c01 100644
--- a/subworkflows/local/starfusion_workflow.nf
+++ b/subworkflows/local/starfusion_workflow.nf
@@ -1,7 +1,8 @@
-include { SAMTOOLS_VIEW as SAMTOOLS_VIEW_FOR_STARFUSION } from '../../modules/nf-core/samtools/view/main'
-include { SAMTOOLS_INDEX as SAMTOOLS_INDEX_FOR_STARFUSION } from '../../modules/nf-core/samtools/index/main'
-include { STAR_ALIGN as STAR_FOR_STARFUSION } from '../../modules/nf-core/star/align/main'
-include { STARFUSION } from '../../modules/local/starfusion/detect/main'
+include { SAMTOOLS_INDEX as SAMTOOLS_INDEX_FOR_STARFUSION } from '../../modules/nf-core/samtools/index/main'
+include { SAMTOOLS_INDEX as SAMTOOLS_INDEX_FOR_STARFUSION_CRAM } from '../../modules/nf-core/samtools/index/main'
+include { SAMTOOLS_VIEW as SAMTOOLS_VIEW_FOR_STARFUSION } from '../../modules/nf-core/samtools/view/main'
+include { STAR_ALIGN as STAR_FOR_STARFUSION } from '../../modules/nf-core/star/align/main'
+include { STARFUSION } from '../../modules/local/starfusion/detect/main'
workflow STARFUSION_WORKFLOW {
take:
@@ -33,6 +34,9 @@ workflow STARFUSION_WORKFLOW {
if (params.cram.contains('starfusion')){
SAMTOOLS_VIEW_FOR_STARFUSION (bam_sorted_indexed, ch_fasta, [] )
ch_versions = ch_versions.mix(SAMTOOLS_VIEW_FOR_STARFUSION.out.versions)
+
+ SAMTOOLS_INDEX_FOR_STARFUSION_CRAM (SAMTOOLS_VIEW_FOR_STARFUSION.out.cram)
+ ch_versions = ch_versions.mix(SAMTOOLS_INDEX_FOR_STARFUSION_CRAM.out.versions)
}
reads_junction = reads.join(STAR_FOR_STARFUSION.out.junction )
@@ -41,16 +45,19 @@ workflow STARFUSION_WORKFLOW {
ch_starfusion_fusions = STARFUSION.out.fusions
ch_star_stats = STAR_FOR_STARFUSION.out.log_final
+ ch_star_gene_count = STAR_FOR_STARFUSION.out.read_per_gene_tab
}
}
else {
ch_starfusion_fusions = reads.combine(Channel.value(file(ch_dummy_file, checkIfExists:true)))
.map { meta, reads, fusions -> [ meta, fusions ] }
ch_star_stats = Channel.empty()
+ ch_star_gene_count = Channel.empty()
}
emit:
fusions = ch_starfusion_fusions
star_stats = ch_star_stats
+ star_gene_count = ch_star_gene_count
ch_bam_sorted = ch_align.ifEmpty([[],[]])
ch_bam_sorted_indexed = bam_sorted_indexed.ifEmpty([[],[],[]])
versions = ch_versions.ifEmpty(null)
diff --git a/subworkflows/local/stringtie_workflow.nf b/subworkflows/local/stringtie_workflow.nf
index d9e1c6c3..93a50e0c 100644
--- a/subworkflows/local/stringtie_workflow.nf
+++ b/subworkflows/local/stringtie_workflow.nf
@@ -12,7 +12,7 @@ workflow STRINGTIE_WORKFLOW {
ch_stringtie_gtf = Channel.empty()
if ((params.stringtie || params.all) && !params.fusioninspector_only) {
- STRINGTIE_STRINGTIE(bam_sorted, ch_chrgtf)
+ STRINGTIE_STRINGTIE(bam_sorted, ch_chrgtf.map { meta, gtf -> [ gtf ]})
ch_versions = ch_versions.mix(STRINGTIE_STRINGTIE.out.versions)
STRINGTIE_STRINGTIE
@@ -21,7 +21,7 @@ workflow STRINGTIE_WORKFLOW {
.map { it -> it[1] }
.set { stringtie_gtf }
- STRINGTIE_MERGE ( stringtie_gtf, ch_chrgtf )
+ STRINGTIE_MERGE (stringtie_gtf, ch_chrgtf.map { meta, gtf -> [ gtf ]})
ch_versions = ch_versions.mix(STRINGTIE_MERGE.out.versions)
ch_stringtie_gtf = STRINGTIE_MERGE.out.gtf
}
diff --git a/subworkflows/local/trim_workflow.nf b/subworkflows/local/trim_workflow.nf
index bf3781f8..61cce26f 100644
--- a/subworkflows/local/trim_workflow.nf
+++ b/subworkflows/local/trim_workflow.nf
@@ -1,5 +1,3 @@
-include { REFORMAT } from '../../modules/local/reformat/main'
-include { FASTQC as FASTQC_FOR_TRIM } from '../../modules/nf-core/fastqc/main'
include { FASTP } from '../../modules/nf-core/fastp/main'
include { FASTQC as FASTQC_FOR_FASTP } from '../../modules/nf-core/fastqc/main'
@@ -10,18 +8,11 @@ workflow TRIM_WORKFLOW {
main:
ch_versions = Channel.empty()
+ ch_fastp_html = Channel.empty()
+ ch_fastp_json = Channel.empty()
+ ch_fastqc_trimmed = Channel.empty()
- if (params.trim) {
-
- REFORMAT( reads )
- ch_versions = ch_versions.mix(REFORMAT.out.versions)
- FASTQC_FOR_TRIM (REFORMAT.out.reads_out)
- ch_versions = ch_versions.mix(FASTQC_FOR_TRIM.out.versions)
-
- ch_reads_all = reads
- ch_reads_fusioncatcher = REFORMAT.out.reads_out
- }
- else if (params.fastp_trim) {
+ if (params.fastp_trim) {
FASTP(reads, params.adapter_fasta, false, false)
ch_versions = ch_versions.mix(FASTP.out.versions)
@@ -30,6 +21,9 @@ workflow TRIM_WORKFLOW {
ch_reads_all = FASTP.out.reads
ch_reads_fusioncatcher = ch_reads_all
+ ch_fastp_html = FASTP.out.html
+ ch_fastp_json = FASTP.out.json
+ ch_fastqc_trimmed = FASTQC_FOR_FASTP.out.zip
}
else {
@@ -40,6 +34,9 @@ workflow TRIM_WORKFLOW {
emit:
ch_reads_all
ch_reads_fusioncatcher
+ ch_fastp_html
+ ch_fastp_json
+ ch_fastqc_trimmed
versions = ch_versions.ifEmpty(null)
}
diff --git a/tower.yml b/tower.yml
index 5813f5d3..2edf5a7f 100644
--- a/tower.yml
+++ b/tower.yml
@@ -13,20 +13,16 @@ reports:
display: "FusionInspector TSV report"
"**/fusionreport/*/*_fusionreport_index.html":
display: "Fusion-report HTML report"
- "**/megafusion/*_fusion_data.vcf":
+ "**/vcf/*_fusion_data.vcf.gz":
display: "Collected statistics on each fusion fed to FusionInspector in VCF format"
"**/picard/*.MarkDuplicates.metrics.txt":
display: "Picard: Metrics from CollectRnaMetrics"
"**/picard/*_rna_metrics.txt":
- display: "Picard: Metrics from MarkDuplicates"
- "**/pizzly/*.pizzly.txt":
- display: "Pizzly identified fusion TXT report"
- "**/qualimap/qualimapReport.html":
- display: "Qualimap HTML report from STAR_FOR_STARFUSION alignment"
- "**/qualimap/rnaseq_qc_results.txt":
- display: "Qualimap QC results from STAR_FOR_STARFUSION alignment in TXT format"
- "**/squid/*.squid.fusions.annotated.txt":
- display: "Squid identified fusion TXT report"
+ display: "GATK4: Metrics from MarkDuplicates"
+ "**/picard/*insert*size*metrics.txt":
+ display: "GATK4: Metrics from InsertSizeMetrics"
+ "**/picard/*pdf":
+ display: "GATK4: InsertSizeMetrics histogram"
"**/star_for_starfusion/*ReadsPerGene.out.tab":
display: "Number of reads per gene"
"**/starfusion/*.starfusion.fusion_predictions.tsv":
diff --git a/workflows/build_references.nf b/workflows/build_references.nf
index 6a03edb6..0ebf3c08 100644
--- a/workflows/build_references.nf
+++ b/workflows/build_references.nf
@@ -8,6 +8,7 @@ include { ARRIBA_DOWNLOAD } from '../modules/local/arriba/downlo
include { ENSEMBL_DOWNLOAD } from '../modules/local/ensembl/main'
include { FUSIONCATCHER_DOWNLOAD } from '../modules/local/fusioncatcher/download/main'
include { FUSIONREPORT_DOWNLOAD } from '../modules/local/fusionreport/download/main'
+include { HGNC_DOWNLOAD } from '../modules/local/hgnc/main'
include { STARFUSION_BUILD } from '../modules/local/starfusion/build/main'
include { STARFUSION_DOWNLOAD } from '../modules/local/starfusion/download/main'
include { GTF_TO_REFFLAT } from '../modules/local/uscs/custom_gtftogenepred/main'
@@ -21,7 +22,6 @@ include { CONVERT2BED } from '../modules/local/convert2bed/m
include { SAMTOOLS_FAIDX } from '../modules/nf-core/samtools/faidx/main'
include { STAR_GENOMEGENERATE } from '../modules/nf-core/star/genomegenerate/main'
-include { KALLISTO_INDEX as PIZZLY_INDEX } from '../modules/nf-core/kallisto/index/main'
include { GATK4_CREATESEQUENCEDICTIONARY } from '../modules/nf-core/gatk4/createsequencedictionary/main'
include { GATK4_BEDTOINTERVALLIST } from '../modules/nf-core/gatk4/bedtointervallist/main'
@@ -36,6 +36,7 @@ workflow BUILD_REFERENCES {
def fake_meta = [:]
fake_meta.id = "Homo_sapiens.${params.genome}.${params.ensembl_version}"
ENSEMBL_DOWNLOAD( params.ensembl_version, params.genome, fake_meta )
+ HGNC_DOWNLOAD( )
SAMTOOLS_FAIDX(ENSEMBL_DOWNLOAD.out.fasta, [[],[]])
@@ -47,7 +48,7 @@ workflow BUILD_REFERENCES {
GATK4_BEDTOINTERVALLIST(CONVERT2BED.out.bed, GATK4_CREATESEQUENCEDICTIONARY.out.dict)
- if (params.starindex || params.all || params.starfusion || params.arriba || params.squid ) {
+ if (params.starindex || params.all || params.starfusion || params.arriba) {
STAR_GENOMEGENERATE( ENSEMBL_DOWNLOAD.out.fasta, ENSEMBL_DOWNLOAD.out.gtf )
}
@@ -59,10 +60,6 @@ workflow BUILD_REFERENCES {
FUSIONCATCHER_DOWNLOAD()
}
- if (params.pizzly || params.all) {
- PIZZLY_INDEX( ENSEMBL_DOWNLOAD.out.transcript )
- }
-
if (params.starfusion || params.all) {
if (params.starfusion_build){
STARFUSION_BUILD( ENSEMBL_DOWNLOAD.out.fasta, ENSEMBL_DOWNLOAD.out.chrgtf )
diff --git a/workflows/rnafusion.nf b/workflows/rnafusion.nf
index 6f498e11..8319b49e 100644
--- a/workflows/rnafusion.nf
+++ b/workflows/rnafusion.nf
@@ -19,6 +19,8 @@ WorkflowRnafusion.initialise(params, log)
if (file(params.input).exists() || params.build_references) { ch_input = file(params.input) } else { exit 1, 'Input samplesheet does not exist or was not specified!' }
if (params.fusioninspector_only && !params.fusioninspector_fusions) { exit 1, 'Parameter --fusioninspector_fusions PATH_TO_FUSION_LIST expected with parameter --fusioninspector_only'}
+if (params.tools_cutoff < 1) { exit 1, 'Parameter: --tools_cutoff should be >= 1'}
+
ch_chrgtf = params.starfusion_build ? Channel.fromPath(params.chrgtf).map { it -> [[id:it.Name], it] }.collect() : Channel.fromPath("${params.starfusion_ref}/ref_annot.gtf").map { it -> [[id:it.Name], it] }.collect()
ch_starindex_ref = params.starfusion_build ? Channel.fromPath(params.starindex_ref).map { it -> [[id:it.Name], it] }.collect() : Channel.fromPath("${params.starfusion_ref}/ref_genome.fa.star.idx").map { it -> [[id:it.Name], it] }.collect()
@@ -30,8 +32,8 @@ ch_arriba_ref_blacklist = Channel.fromPath(params.arriba_ref_blacklist).map { it
ch_arriba_ref_known_fusions = Channel.fromPath(params.arriba_ref_known_fusions).map { it -> [[id:it.Name], it] }.collect()
ch_arriba_ref_protein_domains = Channel.fromPath(params.arriba_ref_protein_domains).map { it -> [[id:it.Name], it] }.collect()
ch_arriba_ref_cytobands = Channel.fromPath(params.arriba_ref_cytobands).map { it -> [[id:it.Name], it] }.collect()
-
-
+ch_hgnc_ref = Channel.fromPath(params.hgnc_ref).map { it -> [[id:it.Name], it] }.collect()
+ch_hgnc_date = Channel.fromPath(params.hgnc_date).map { it -> [[id:it.Name], it] }.collect()
ch_fasta = Channel.fromPath(params.fasta).map { it -> [[id:it.Name], it] }.collect()
ch_gtf = Channel.fromPath(params.gtf).map { it -> [[id:it.Name], it] }.collect()
ch_transcript = Channel.fromPath(params.transcript).map { it -> [[id:it.Name], it] }.collect()
@@ -54,7 +56,6 @@ if (params_fasta_path_uri){
else {
for (param in checkPathParamList) if ((param.toString())!= file(param).toString() && !params.build_references) { exit 1, "Problem with ${param}: ABSOLUTE PATHS are required! Check for trailing '/' at the end of paths too." }
}
-if ((params.squid || params.all) && params.ensembl_version != 102) { exit 1, 'Ensembl version is not supported by squid' }
/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -80,9 +81,7 @@ ch_multiqc_custom_methods_description = params.multiqc_methods_description ? fil
include { INPUT_CHECK } from '../subworkflows/local/input_check'
include { TRIM_WORKFLOW } from '../subworkflows/local/trim_workflow'
include { ARRIBA_WORKFLOW } from '../subworkflows/local/arriba_workflow'
-include { PIZZLY_WORKFLOW } from '../subworkflows/local/pizzly_workflow'
include { QC_WORKFLOW } from '../subworkflows/local/qc_workflow'
-include { SQUID_WORKFLOW } from '../subworkflows/local/squid_workflow'
include { STARFUSION_WORKFLOW } from '../subworkflows/local/starfusion_workflow'
include { STRINGTIE_WORKFLOW } from '../subworkflows/local/stringtie_workflow'
include { FUSIONCATCHER_WORKFLOW } from '../subworkflows/local/fusioncatcher_workflow'
@@ -180,26 +179,6 @@ workflow RNAFUSION {
)
ch_versions = ch_versions.mix(ARRIBA_WORKFLOW.out.versions.first().ifEmpty(null))
- // Run pizzly/kallisto
-
- PIZZLY_WORKFLOW (
- ch_reads_all,
- ch_gtf,
- ch_transcript
- )
- ch_versions = ch_versions.mix(PIZZLY_WORKFLOW.out.versions.first().ifEmpty(null))
-
-
-// Run squid
-
- SQUID_WORKFLOW (
- ch_reads_all,
- ch_gtf,
- ch_starindex_ensembl_ref,
- ch_fasta
- )
- ch_versions = ch_versions.mix(SQUID_WORKFLOW.out.versions.first().ifEmpty(null))
-
//Run STAR fusion
STARFUSION_WORKFLOW (
@@ -231,8 +210,6 @@ workflow RNAFUSION {
ch_reads_all,
ch_fusionreport_ref,
ARRIBA_WORKFLOW.out.fusions,
- PIZZLY_WORKFLOW.out.fusions,
- SQUID_WORKFLOW.out.fusions,
STARFUSION_WORKFLOW.out.fusions,
FUSIONCATCHER_WORKFLOW.out.fusions
)
@@ -245,10 +222,13 @@ workflow RNAFUSION {
FUSIONREPORT_WORKFLOW.out.fusion_list,
FUSIONREPORT_WORKFLOW.out.fusion_list_filtered,
FUSIONREPORT_WORKFLOW.out.report,
+ FUSIONREPORT_WORKFLOW.out.csv,
STARFUSION_WORKFLOW.out.ch_bam_sorted_indexed,
ch_chrgtf,
ch_arriba_ref_protein_domains,
- ch_arriba_ref_cytobands
+ ch_arriba_ref_cytobands,
+ ch_hgnc_ref,
+ ch_hgnc_date
)
ch_versions = ch_versions.mix(FUSIONINSPECTOR_WORKFLOW.out.versions.first().ifEmpty(null))
@@ -284,10 +264,15 @@ workflow RNAFUSION {
ch_multiqc_files = ch_multiqc_files.mix(ch_methods_description.collectFile(name: 'methods_description_mqc.yaml'))
ch_multiqc_files = ch_multiqc_files.mix(CUSTOM_DUMPSOFTWAREVERSIONS.out.mqc_yml.collect())
ch_multiqc_files = ch_multiqc_files.mix(FASTQC.out.zip.collect{it[1]}.ifEmpty([]))
- ch_multiqc_files = ch_multiqc_files.mix(QC_WORKFLOW.out.qualimap_qc.collect{it[1]}.ifEmpty([]))
+ ch_multiqc_files = ch_multiqc_files.mix(TRIM_WORKFLOW.out.ch_fastp_html.collect{it[1]}.ifEmpty([]))
+ ch_multiqc_files = ch_multiqc_files.mix(TRIM_WORKFLOW.out.ch_fastp_json.collect{it[1]}.ifEmpty([]))
+ ch_multiqc_files = ch_multiqc_files.mix(TRIM_WORKFLOW.out.ch_fastqc_trimmed.collect{it[1]}.ifEmpty([]))
ch_multiqc_files = ch_multiqc_files.mix(STARFUSION_WORKFLOW.out.star_stats.collect{it[1]}.ifEmpty([]))
+ ch_multiqc_files = ch_multiqc_files.mix(STARFUSION_WORKFLOW.out.star_gene_count.collect{it[1]}.ifEmpty([]))
ch_multiqc_files = ch_multiqc_files.mix(QC_WORKFLOW.out.rnaseq_metrics.collect{it[1]}.ifEmpty([]))
ch_multiqc_files = ch_multiqc_files.mix(QC_WORKFLOW.out.duplicate_metrics.collect{it[1]}.ifEmpty([]))
+ ch_multiqc_files = ch_multiqc_files.mix(QC_WORKFLOW.out.insertsize_metrics.collect{it[1]}.ifEmpty([]))
+ ch_multiqc_files = ch_multiqc_files.mix(FUSIONINSPECTOR_WORKFLOW.out.ch_arriba_visualisation.collect{it[1]}.ifEmpty([]))
@@ -315,6 +300,7 @@ workflow.onComplete {
if (params.email || params.email_on_fail) {
NfcoreTemplate.email(workflow, params, summary_params, projectDir, log, multiqc_report)
}
+ NfcoreTemplate.dump_parameters(workflow, params)
NfcoreTemplate.summary(workflow, params, log)
if (params.hook_url) {
NfcoreTemplate.IM_notification(workflow, params, summary_params, projectDir, log)
|