From 34dc6e5a8125edb00f5bcf16ebe434aee8bfc3af Mon Sep 17 00:00:00 2001 From: Joon-Klaps Date: Wed, 30 Oct 2024 11:17:32 +0000 Subject: [PATCH] adding params in config --- nf_core/pipeline-template/conf/test.config | 6 ++++++ nf_core/pipeline-template/conf/test_full.config | 6 ++++++ nf_core/pipeline-template/nextflow.config | 7 +++++++ nf_core/pipeline-template/workflows/pipeline.nf | 8 +++++--- 4 files changed, 24 insertions(+), 3 deletions(-) diff --git a/nf_core/pipeline-template/conf/test.config b/nf_core/pipeline-template/conf/test.config index bea6f670d0..0c2f9392fc 100644 --- a/nf_core/pipeline-template/conf/test.config +++ b/nf_core/pipeline-template/conf/test.config @@ -31,4 +31,10 @@ params { // Genome references genome = 'R64-1-1' {%- endif %} + + {% if downstream_samplesheets -%} + // Downstream samplesheets + generate_downstream_samplesheets = true + generate_pipeline_samplesheets = 'rnaseq' + {%- endif %} } diff --git a/nf_core/pipeline-template/conf/test_full.config b/nf_core/pipeline-template/conf/test_full.config index aa3b70c1e5..e01c4a8bc6 100644 --- a/nf_core/pipeline-template/conf/test_full.config +++ b/nf_core/pipeline-template/conf/test_full.config @@ -26,4 +26,10 @@ params { // Fasta references fasta = params.pipelines_testdata_base_path + 'viralrecon/genome/NC_045512.2/GCF_009858895.2_ASM985889v3_genomic.200409.fna.gz' {%- endif %} + + {% if downstream_samplesheets -%} + // Downstream samplesheets + generate_downstream_samplesheets = true + generate_pipeline_samplesheets = 'rnaseq' + {%- endif %} } diff --git a/nf_core/pipeline-template/nextflow.config b/nf_core/pipeline-template/nextflow.config index 0afaaa6785..05e82de55c 100644 --- a/nf_core/pipeline-template/nextflow.config +++ b/nf_core/pipeline-template/nextflow.config @@ -29,6 +29,13 @@ params { {% if citations %}multiqc_methods_description = null{% endif %} {%- endif %} + {% if downstream_samplesheet -%} + // Downstream samplesheet generation + generate_downstream_samplesheets = false + generate_pipeline_samplesheets = null + generate_pipeline_samplesheets_format = 'csv' + {%- endif %} + // Boilerplate options outdir = null {% if modules %}publish_dir_mode = 'copy'{% endif %} diff --git a/nf_core/pipeline-template/workflows/pipeline.nf b/nf_core/pipeline-template/workflows/pipeline.nf index c268f6e5ba..fd7a29b904 100644 --- a/nf_core/pipeline-template/workflows/pipeline.nf +++ b/nf_core/pipeline-template/workflows/pipeline.nf @@ -47,9 +47,11 @@ workflow {{ short_name|upper }} { // // SUBWORKFLOW: Generate downstream samplesheets // - GENERATE_DOWNSTREAM_SAMPLESHEETS( - ch_samplesheet - ) + if (params.generate_downstream_samplesheets) { + GENERATE_DOWNSTREAM_SAMPLESHEETS( + ch_samplesheet + ) + } {% endif %} //