Skip to content

Commit 9e9d930

Browse files
committed
remove def from nextflow.config and add trace_report_suffix param
1 parent 4e4bbaa commit 9e9d930

File tree

2 files changed

+12
-6
lines changed

2 files changed

+12
-6
lines changed

nf_core/pipeline-template/nextflow.config

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ params {
5252
version = false
5353
{%- if test_config %}
5454
pipelines_testdata_base_path = 'https://raw.githubusercontent.com/nf-core/test-datasets/'{% endif %}
55+
trace_report_suffix = new java.util.Date().format( 'yyyy-MM-dd_HH-mm-ss')
5556

5657
{%- if nf_core_configs -%}
5758
// Config options
@@ -249,22 +250,21 @@ set -C # No clobber - prevent output redirection from overwriting files.
249250
// Disable process selector warnings by default. Use debug profile to enable warnings.
250251
nextflow.enable.configProcessNamesValidation = false
251252

252-
def trace_timestamp = new java.util.Date().format( 'yyyy-MM-dd_HH-mm-ss')
253253
timeline {
254254
enabled = true
255-
file = "${params.outdir}/pipeline_info/execution_timeline_${trace_timestamp}.html"
255+
file = "${params.outdir}/pipeline_info/execution_timeline_${params.trace_report_suffix}.html"
256256
}
257257
report {
258258
enabled = true
259-
file = "${params.outdir}/pipeline_info/execution_report_${trace_timestamp}.html"
259+
file = "${params.outdir}/pipeline_info/execution_report_${params.trace_report_suffix}.html"
260260
}
261261
trace {
262262
enabled = true
263-
file = "${params.outdir}/pipeline_info/execution_trace_${trace_timestamp}.txt"
263+
file = "${params.outdir}/pipeline_info/execution_trace_${params.trace_report_suffix}.txt"
264264
}
265265
dag {
266266
enabled = true
267-
file = "${params.outdir}/pipeline_info/pipeline_dag_${trace_timestamp}.html"
267+
file = "${params.outdir}/pipeline_info/pipeline_dag_${params.trace_report_suffix}.html"
268268
}
269269

270270
manifest {

nf_core/pipeline-template/nextflow_schema.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,13 @@
229229
"description": "Base URL or local path to location of pipeline test dataset files",
230230
"default": "https://raw.githubusercontent.com/nf-core/test-datasets/",
231231
"hidden": true
232-
}{% endif %}
232+
}{% endif %},
233+
"trace_report_suffix": {
234+
"type": "string",
235+
"fa_icon": "far calendar",
236+
"description": "Suffix to add to the trace report filename. Default is the date and time in the format yyyy-MM-dd_HH-mm-ss.",
237+
"hidden": true
238+
}
233239
}
234240
}
235241
},

0 commit comments

Comments
 (0)