-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
We should incorporate the new methods.setup_process_afterscript() from uclahs-cds/pipeline-Nextflow-config#64 into this pipeline.
Under the new method, log files are automatically saved to ${params.log_output_dir}/process-log/${task.ext.log_dir}${task.ext.log_dir_suffix}/ (no need to specify a publishDir directive).
${task.ext.log_dir} defaults to ${task.process.replace(':', '/')}.
${task.ext.log_dir_suffix} defaults to a blank string.
The key steps are:
- Add
methods.setup_process_afterscript()tomethods.setup(). - For each Nextflow process:
- Remove the
file ".command.*"outputdirective. - Add
ext log_dir { ... }andext log_sur_suffix { ... }directives, if appropriate. - Remove the
publishDirdirective withpattern: ".command.*".
- Remove the
As an example, this publishDir directive...
pipeline-call-gSNP/module/haplotypecaller.nf
Lines 33 to 36 in 56cc6be
| publishDir path: "${params.log_output_dir}/process-log", | |
| pattern: ".command.*", | |
| mode: "copy", | |
| saveAs: { "${task.process.replace(':', '/')}/${task.process.split(':')[-1]}-${sample_id}-${interval_id}/log${file(it).getName()}" } |
... should be replaced with this directive:
ext log_dir_suffix { "/${task.process.split(':')[-1]}-${sample_id}-${interval_id}" }See https://github.com/uclahs-cds/pipeline-recalibrate-BAM/pull/76/files for a full example.
Metadata
Metadata
Assignees
Labels
No labels