Skip to content

Commit 4f91ec0

Browse files
authored
Update worklow output definitions to 25.04.0 (#115)
* update workflow-output-defs to 25.04.0 * update tests * update changelog
1 parent 4bc3068 commit 4f91ec0

9 files changed

Lines changed: 389 additions & 394 deletions

File tree

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,15 @@ concurrency:
2121
cancel-in-progress: true
2222

2323
jobs:
24-
test_all:
24+
test:
2525
name: Run nf-test with ${{ matrix.test }}-${{ matrix.NXF_VER }}
2626
# Only run on push if this is the nf-core dev branch (merged PRs)
2727
if: "${{ github.event_name != 'push' || (github.event_name == 'push' && github.repository == 'nf-cmgg/structural') }}"
2828
runs-on: ubuntu-latest
2929
strategy:
3030
matrix:
3131
NXF_VER:
32-
- "24.10.0"
32+
- "25.04.0"
3333
- "latest-everything"
3434
test:
3535
- "pipeline_sv"

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1919
4. Updated to nf-core template v3.2.0
2020
5. Fixed language server errors
2121
6. Removed the old output publishing code and used the new workflow output definitions instead
22-
7. Bumped the minimal nextflow version to 24.10.0
22+
7. Bumped the minimal nextflow version to 25.04.0
2323
8. VCFanno will now run when `--vcfanno_toml` has been given and `--annotate` has not been given. You still need to supply `--annotate` to get the full annotation, but this can be used check for common variants without having to perform full annotation.
2424
9. Changed the `--annotations_filter` parameter to a `--filter` parameter. This parameter takes an argument of `bcftools filter` to filter the resulting VCFs.
2525
10. Removed the `--delly_sv_types` parameter.
26+
11. Moved all `wisecondorx` and `qdnaseq` outputs to a separate directory in each sample output.
2627

2728
### `Fixed`
2829

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
[![GitHub Actions Linting Status](https://github.com/nf-cmgg/structural/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-cmgg/structural/actions/workflows/linting.yml)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.XXXXXXX)
55
[![nf-test](https://img.shields.io/badge/unit_tests-nf--test-337ab7.svg)](https://www.nf-test.com)
66

7-
[![Nextflow](https://img.shields.io/badge/nextflow%20DSL2-%E2%89%A524.10.0-23aa62.svg)](https://www.nextflow.io/)
7+
[![Nextflow](https://img.shields.io/badge/nextflow%20DSL2-%E2%89%A525.04.0-23aa62.svg)](https://www.nextflow.io/)
88
[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/)
99
[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)
1010
[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)

main.nf

Lines changed: 47 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -128,74 +128,68 @@ workflow {
128128
)
129129

130130
publish:
131-
STRUCTURAL.out.caller_vcfs >> 'caller_vcfs'
132-
STRUCTURAL.out.sample_vcfs >> 'sample_vcfs'
133-
STRUCTURAL.out.family_vcfs >> 'family_vcfs'
134-
STRUCTURAL.out.qdnaseq_out >> 'qdnaseq_out'
135-
STRUCTURAL.out.wisecondorx_out >> 'wisecondorx_out'
136-
STRUCTURAL.out.bedpe >> 'bedpe'
137-
STRUCTURAL.out.multiqc_report >> 'multiqc'
138-
STRUCTURAL.out.multiqc_data >> 'multiqc_data'
131+
caller_vcfs = STRUCTURAL.out.caller_vcfs
132+
sample_vcfs = STRUCTURAL.out.sample_vcfs
133+
family_vcfs = STRUCTURAL.out.family_vcfs
134+
qdnaseq_out = STRUCTURAL.out.qdnaseq_out
135+
wisecondorx_out = STRUCTURAL.out.wisecondorx_out
136+
bedpe = STRUCTURAL.out.bedpe
137+
multiqc = STRUCTURAL.out.multiqc_report
138+
multiqc_data = STRUCTURAL.out.multiqc_data
139139

140140
}
141141

142142
output {
143-
'caller_vcfs' {
143+
caller_vcfs {
144144
enabled params.output_callers
145-
path { meta, vcf, _tbi -> { file ->
146-
if(file == vcf.name) {
147-
return "${meta.sample}/${meta.caller}/${meta.sample}.vcf.gz"
148-
}
149-
return "${meta.sample}/${meta.caller}/${meta.sample}.vcf.gz.tbi"
150-
} }
145+
path { meta, vcf, tbi ->
146+
vcf >> "${meta.sample}/${meta.caller}/${meta.sample}.vcf.gz"
147+
tbi >> "${meta.sample}/${meta.caller}/${meta.sample}.vcf.gz.tbi"
148+
}
151149
}
152-
'sample_vcfs' {
153-
path { meta, vcf, _tbi -> { file ->
150+
sample_vcfs {
151+
path { meta, vcf, tbi ->
154152
def base = "${meta.id}/${meta.id}${meta.variant_type ? '.' + meta.variant_type : ''}"
155-
if(file == vcf.name) {
156-
return "${base}.vcf.gz"
157-
}
158-
return "${base}.vcf.gz.tbi"
159-
} }
153+
vcf >> "${base}.vcf.gz"
154+
tbi >> "${base}.vcf.gz.tbi"
155+
}
160156
}
161-
'family_vcfs' {
162-
path { meta, vcf, _tbi -> { file ->
157+
family_vcfs {
158+
path { meta, vcf, tbi ->
163159
def base = "${meta.id}/${meta.id}${meta.variant_type ? '.' + meta.variant_type : ''}"
164-
if(file == vcf.name) {
165-
return "${base}.vcf.gz"
166-
}
167-
return "${base}.vcf.gz.tbi"
168-
} }
160+
vcf >> "${base}.vcf.gz"
161+
tbi >> "${base}.vcf.gz.tbi"
162+
}
169163
}
170-
'qdnaseq_out' {
171-
path { meta, _bed -> { file ->
172-
if(file == "statistics.out") {
173-
return "${meta.id}/${meta.id}.qdnaseq.statistics.out"
174-
}
175-
def new_name = file.replaceFirst(meta.id, "${meta.id}.qdnaseq")
176-
return "${meta.id}/${new_name}"
177-
} }
164+
qdnaseq_out {
165+
path { meta, _bed_qdnaseq -> "$meta.id/qdnaseq/"
166+
// def base_suffix = bed_qdnaseq.name.replace(meta.id, "${meta.id}.qdnaseq")
167+
// bed_qdnaseq >> bed_qdnaseq.name == "statistics.out" ?
168+
// "${meta.id}/${meta.id}.qdnaseq.statistics.out" :
169+
// "${meta.id}/${base_suffix}"
170+
}
178171
}
179-
'wisecondorx_out' {
180-
path { meta, _bed -> { file ->
181-
if(file.endsWith(".png")) {
182-
return "${meta.id}/${meta.id}.wisecondorx.${file}"
183-
}
184-
def new_name = file.replaceFirst(meta.id, "${meta.id}.wisecondorx")
185-
return "${meta.id}/${new_name}"
186-
} }
172+
wisecondorx_out {
173+
path { meta, _bed -> "$meta.id/wisecondorx/"
174+
// if(bed.name.endsWith(".png")) {
175+
// bed >> "${meta.id}/${meta.id}.wisecondorx.${bed.name}"
176+
// } else {
177+
// def new_name = bed.name.replaceFirst(meta.id, "${meta.id}.wisecondorx")
178+
// bed >> "${meta.id}/${new_name}"
179+
// }
180+
}
187181
}
188-
'bedpe' {
189-
path { meta, _bedpe -> { file ->
182+
bedpe {
183+
path { meta, bedpe ->
190184
def base = "${meta.id}/${meta.id}${meta.variant_type ? '.' + meta.variant_type : ''}"
191-
return "${base}.bedpe"
192-
} }
185+
bedpe >> "${base}.bedpe"
186+
}
193187
}
194-
'multiqc' {
195-
path { _report -> { _file -> "multiqc/multiqc_report.html"}}
188+
multiqc {
189+
path { "multiqc/" }
196190
}
197-
'multiqc_data' {
198-
path { _folder -> { _file -> "multiqc/multiqc_data"}}
191+
multiqc_data {
192+
path { "multiqc/" }
199193
}
200194
}
201195

nextflow.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@ manifest {
279279
description = """A bioinformatics best-practice analysis pipeline for calling structural variants (SVs), copy number variants (CNVs) and repeat region expansions (RREs) from short DNA reads."""
280280
mainScript = 'main.nf'
281281
defaultBranch = 'main'
282-
nextflowVersion = '!>=24.10.0'
282+
nextflowVersion = '!>=25.04.0'
283283
version = '0.3.0dev'
284284
doi = ''
285285
}

0 commit comments

Comments
 (0)