From 53ef005f0a1387c320ce6b3cf25363794fe7dde9 Mon Sep 17 00:00:00 2001 From: Thiseas Christos Lamnidis Date: Fri, 29 Nov 2024 15:35:52 +0100 Subject: [PATCH 1/4] put fastp results in own directory --- conf/modules.config | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/conf/modules.config b/conf/modules.config index 09fbff1fc..aace67cf4 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -103,13 +103,13 @@ process { ext.prefix = { "${meta.sample_id}_${meta.library_id}_L${meta.lane}" } publishDir = [ [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/fastp" }, mode: params.publish_dir_mode, pattern: '*.fastq.gz', enabled: params.preprocessing_savepreprocessedreads ], [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/fastp" }, mode: params.publish_dir_mode, pattern: '*.{log,html,json}' ] @@ -133,13 +133,13 @@ process { ext.prefix = { "${meta.sample_id}_${meta.library_id}_L${meta.lane}" } publishDir = [ [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/fastp" }, mode: params.publish_dir_mode, pattern: '*.fastq.gz', enabled: params.preprocessing_savepreprocessedreads ], [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/fastp" }, mode: params.publish_dir_mode, pattern: '*.{log,html,json}' ] From d36dee2660a7c96059642e80e62232aa722ccf90 Mon Sep 17 00:00:00 2001 From: Thiseas Christos Lamnidis Date: Fri, 29 Nov 2024 15:36:45 +0100 Subject: [PATCH 2/4] Put adapter removal results in own directory --- conf/modules.config | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/conf/modules.config b/conf/modules.config index aace67cf4..612e83d46 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -165,13 +165,13 @@ process { ext.prefix = { "${meta.sample_id}_${meta.library_id}_L${meta.lane}" } publishDir = [ [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/adapterremoval" }, mode: params.publish_dir_mode, pattern: '*.fastq.gz', enabled: params.preprocessing_savepreprocessedreads ], [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/adapterremoval" }, mode: params.publish_dir_mode, pattern: '*.settings' ] @@ -199,13 +199,13 @@ process { ext.prefix = { "${meta.sample_id}_${meta.library_id}_L${meta.lane}" } publishDir = [ [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/adapterremoval" }, mode: params.publish_dir_mode, pattern: '*.fastq.gz', enabled: params.preprocessing_savepreprocessedreads ], [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/adapterremoval" }, mode: params.publish_dir_mode, pattern: '*.settings' ] @@ -216,7 +216,7 @@ process { tag = { "${meta.sample_id}_${meta.library_id}_L${meta.lane}_${meta.reference}" } ext.prefix = { "${meta.sample_id}_${meta.library_id}_L${meta.lane}_${meta.reference}" } publishDir = [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/preprocessing/adapterremoval" }, mode: params.publish_dir_mode, pattern: '*.fastq.gz', enabled: params.preprocessing_savepreprocessedreads From 038ab3d3028514704fe54c391a16ac404fdaba75 Mon Sep 17 00:00:00 2001 From: Thiseas Christos Lamnidis Date: Fri, 29 Nov 2024 15:37:49 +0100 Subject: [PATCH 3/4] fix bam_filtering result directory name. Minor formatting changes --- conf/modules.config | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/conf/modules.config b/conf/modules.config index 612e83d46..7608564d9 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -335,7 +335,7 @@ process { tag = { "${meta.sample_id}_${meta.library_id}_${meta.reference}" } ext.prefix = { "${meta.sample_id}_${meta.library_id}_${meta.reference}" } publishDir = [ - path: { "${params.outdir}/preprocessing" }, + path: { "${params.outdir}/bam_filtering/" }, mode: params.publish_dir_mode, pattern: '*.fastq.gz', enabled: params.preprocessing_savepreprocessedreads @@ -862,7 +862,7 @@ process { path: { "${params.outdir}/damage_manipulation/" }, mode: params.publish_dir_mode, pattern: '*.{bai,csi}' - ] + ] } // @@ -1115,7 +1115,7 @@ process { ext.prefix = { "${meta2.id}_samtoolsdepth" } ext.args = '-aa -q30 -Q30 -H' publishDir = [ - enabled: false + enabled: false ] } From 9ae841589cd3d7624282495d7a25e6880dcb9313 Mon Sep 17 00:00:00 2001 From: Thiseas Christos Lamnidis Date: Fri, 29 Nov 2024 15:38:38 +0100 Subject: [PATCH 4/4] exclude versions.yml from published results. remove enabled:true statements from publishDirs. --- conf/modules.config | 51 ++++++++++++++++++++++----------------------- 1 file changed, 25 insertions(+), 26 deletions(-) diff --git a/conf/modules.config b/conf/modules.config index 7608564d9..67e030eef 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -47,6 +47,7 @@ process { publishDir = [ path: { "${params.outdir}/preprocessing/fastqc_raw/" }, mode: params.publish_dir_mode, + pattern: '*[!versions.yml]', ] } @@ -57,6 +58,7 @@ process { publishDir = [ path: { "${params.outdir}/preprocessing/fastqc_processed/" }, mode: params.publish_dir_mode, + pattern: '*[!versions.yml]', ] } @@ -76,6 +78,7 @@ process { publishDir = [ path: { "${params.outdir}/preprocessing/falco_raw/" }, mode: params.publish_dir_mode, + pattern: '*[!versions.yml]', ] } @@ -86,6 +89,7 @@ process { publishDir = [ path: { "${params.outdir}/preprocessing/falco_processed/" }, mode: params.publish_dir_mode, + pattern: '*[!versions.yml]', ] } @@ -704,7 +708,8 @@ process { ext.prefix = { "${meta.sample_id}_${meta.library_id}_${meta.reference}" } publishDir = [ path: { "${params.outdir}/mapstats/preseq" }, - mode: params.publish_dir_mode + mode: params.publish_dir_mode, + pattern: '*[!versions.yml]', ] } @@ -722,7 +727,8 @@ process { ext.prefix = { "${meta.sample_id}_${meta.library_id}_${meta.reference}" } publishDir = [ path: { "${params.outdir}/mapstats/preseq" }, - mode: params.publish_dir_mode + mode: params.publish_dir_mode, + pattern: '*[!versions.yml]', ] } @@ -742,7 +748,8 @@ process { ext.prefix = { "${meta.sample_id}_${meta.reference}_depth" } publishDir = [ path: { "${params.outdir}/mapstats/bedtools" }, - mode: params.publish_dir_mode + mode: params.publish_dir_mode, + pattern: '*[!versions.yml]', ] } @@ -752,7 +759,8 @@ process { ext.prefix = { "${meta.sample_id}_${meta.reference}_breadth" } publishDir = [ path: { "${params.outdir}/mapstats/bedtools" }, - mode: params.publish_dir_mode + mode: params.publish_dir_mode, + pattern: '*[!versions.yml]', ] } @@ -1066,9 +1074,9 @@ process { withName: 'QUALIMAP_BAMQC_WITHBED|QUALIMAP_BAMQC_NOBED' { tag = { "${meta.reference}|${meta.sample_id}" } publishDir = [ - path: { "${params.outdir}/mapstats/qualimap/${meta.reference}/${meta.sample_id}/}" }, + path: { "${params.outdir}/mapstats/qualimap/${meta.reference}/" }, mode: params.publish_dir_mode, - enabled: true + pattern: '*[!versions.yml]', ] } @@ -1086,7 +1094,7 @@ process { publishDir = [ path: { "${params.outdir}/damage_estimation/damageprofiler/" }, mode: params.publish_dir_mode, - enabled: true + pattern: '*[!versions.yml]' ] } @@ -1250,8 +1258,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.{geno,snp,ind}' + pattern: '*.{geno,snp,ind}', ] } @@ -1262,8 +1269,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.{tsv}' + pattern: '*.{tsv}', ] } @@ -1285,9 +1291,9 @@ process { ].join(' ').trim() ext.prefix = { "${meta.sample_id}_${meta.reference}_realigned" } publishDir = [ + enabled: params.genotyping_gatk_ug_keeprealignbam, path: { "${params.outdir}/genotyping/IndelRealigner" }, mode: params.publish_dir_mode, - enabled: params.genotyping_gatk_ug_keeprealignbam, pattern: '*.{bam,bai}' ] } @@ -1306,8 +1312,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.vcf.gz' + pattern: '*.vcf.gz', ] } @@ -1318,8 +1323,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.vcf.gz.tbi' + pattern: '*.vcf.gz.tbi', ] } @@ -1336,8 +1340,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.{vcf.gz,vcf.gz.tbi}' + pattern: '*.{vcf.gz,vcf.gz.tbi}', ] } @@ -1352,8 +1355,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.vcf.gz' + pattern: '*.vcf.gz', ] } @@ -1364,8 +1366,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.vcf.gz.tbi' + pattern: '*.vcf.gz.tbi', ] } @@ -1375,8 +1376,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.txt' + pattern: '*.txt', ] } @@ -1395,8 +1395,7 @@ process { publishDir = [ path: { "${params.outdir}/genotyping/" }, mode: params.publish_dir_mode, - enabled: true, - pattern: '*.{glf,beagle}.gz' + pattern: '*.{glf,beagle}.gz', ] } }