Lili Andersson-Li
07/22/2024, 11:03 AMpublishDir to stop publishing the empty files?
withName: EXTRACTCDIAMONDREADS {
ext.prefix = { "${meta.id}" }
publishDir = [
path: { "${params.outdir}/extracted_reads/diamond" },
mode: params.publish_dir_mode,
pattern: '*.fastq',
filter: { file -> file.size() > 0 }
]
}Ashley Dederich
07/22/2024, 1:44 PMRike Hanssen
07/23/2024, 5:23 PMpublishDir. You could try with saveAs for some conditionals. Is there an option to prevent creating empty files in the first place? https://www.nextflow.io/docs/latest/process.html#publishdirLili Andersson-Li
07/24/2024, 7:38 AMsaveAs: { file -> file.size() > 0 } , but didn’t work. I think I will write a short process to remove them for now.Rike Hanssen
07/24/2024, 7:39 AMLili Andersson-Li
07/24/2024, 7:41 AM