Skip to content

Commit

Permalink
Add output definition
Browse files Browse the repository at this point in the history
Signed-off-by: Ben Sherman <[email protected]>
  • Loading branch information
bentsherman committed Feb 28, 2024
1 parent b03ed3b commit b8dd9e2
Show file tree
Hide file tree
Showing 13 changed files with 40 additions and 85 deletions.
6 changes: 0 additions & 6 deletions conf/base.config
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,6 @@ process {
memory = { check_max( 6.GB * task.attempt, 'memory' ) }
time = { check_max( 4.h * task.attempt, 'time' ) }

publishDir = [
path: { "${params.outdir}/${task.process.tokenize(':')[-1].tokenize('_')[0].toLowerCase()}" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]

errorStrategy = { task.exitStatus in ((130..145) + 104) ? 'retry' : 'finish' }
maxRetries = 1
maxErrors = '-1'
Expand Down
40 changes: 40 additions & 0 deletions main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,46 @@ workflow {
)
}

output {
path params.outdir

collect('fastq') {
select('ASPERA_CLI|SRA_FASTQ_FTP|SRATOOLS_FASTERQDUMP') {
path 'fastq'
pattern '*.fastq.gz'
}

select('ASPERA_CLI|SRA_FASTQ_FTP') {
path 'fastq/md5'
pattern '*.md5'
}
}

collect('metadata') {
path 'metadata'
select('SRA_RUNINFO_TO_FTP') {
pattern '*.tsv'
}
}

collect('samplesheet') {
path 'samplesheet'
select('MULTIQC_MAPPINGS_CONFIG') {
pattern 'multiqc_config.yml'
}

// index {
// format 'csv'
// path 'id_mappings.csv'
// }

// index {
// format 'csv'
// path 'samplesheet.csv'
// }
}
}

/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
THE END
Expand Down
12 changes: 0 additions & 12 deletions modules/local/aspera_cli/nextflow.config
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
process {
withName: 'ASPERA_CLI' {
ext.args = '-QT -l 300m -P33001'
publishDir = [
[
path: { "${params.outdir}/fastq" },
mode: params.publish_dir_mode,
pattern: "*.fastq.gz"
],
[
path: { "${params.outdir}/fastq/md5" },
mode: params.publish_dir_mode,
pattern: "*.md5"
]
]
}
}
9 changes: 0 additions & 9 deletions modules/local/multiqc_mappings_config/nextflow.config

This file was deleted.

12 changes: 0 additions & 12 deletions modules/local/sra_fastq_ftp/nextflow.config
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
process {
withName: 'SRA_FASTQ_FTP' {
ext.args = '-t 5 -nv -c -T 60'
publishDir = [
[
path: { "${params.outdir}/fastq" },
mode: params.publish_dir_mode,
pattern: "*.fastq.gz"
],
[
path: { "${params.outdir}/fastq/md5" },
mode: params.publish_dir_mode,
pattern: "*.md5"
]
]
}
}
8 changes: 0 additions & 8 deletions modules/local/sra_ids_to_runinfo/nextflow.config

This file was deleted.

9 changes: 0 additions & 9 deletions modules/local/sra_runinfo_to_ftp/nextflow.config

This file was deleted.

8 changes: 0 additions & 8 deletions modules/local/sra_to_samplesheet/nextflow.config

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions modules/nf-core/sratools/fasterqdump/nextflow.config

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 0 additions & 8 deletions modules/nf-core/sratools/prefetch/nextflow.config

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions workflows/sra/nextflow.config
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
includeConfig "../../modules/local/multiqc_mappings_config/nextflow.config"
includeConfig "../../modules/local/aspera_cli/nextflow.config"
includeConfig "../../modules/local/sra_fastq_ftp/nextflow.config"
includeConfig "../../modules/local/sra_ids_to_runinfo/nextflow.config"
includeConfig "../../modules/local/sra_runinfo_to_ftp/nextflow.config"
includeConfig "../../modules/local/sra_to_samplesheet/nextflow.config"
includeConfig "../../modules/nf-core/sratools/prefetch/nextflow.config"
includeConfig "../../subworkflows/nf-core/fastq_download_prefetch_fasterqdump_sratools/nextflow.config"

0 comments on commit b8dd9e2

Please sign in to comment.