diff --git a/modules/nf-core/samtools/sort/main.nf b/modules/nf-core/samtools/sort/main.nf index d4bd5a32715a..01e854bf77d1 100644 --- a/modules/nf-core/samtools/sort/main.nf +++ b/modules/nf-core/samtools/sort/main.nf @@ -19,8 +19,8 @@ process SAMTOOLS_SORT { tuple val(meta), path("${prefix}.${extension}.crai"), emit: crai, optional: true tuple val(meta), path("${prefix}.${extension}.csi"), emit: csi, optional: true tuple val(meta), path("${prefix}.${extension}.bai"), emit: bai, optional: true - path "versions.yml", emit: versions - + tuple val("${task.process}"), val('samtools'), eval("samtools version | sed '1!d;s/.* //'"), topic: versions, emit: versions_samtools + when: task.ext.when == null || task.ext.when @@ -53,10 +53,6 @@ process SAMTOOLS_SORT { -o ${output_file} \\ - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') - END_VERSIONS """ stub: @@ -77,10 +73,6 @@ process SAMTOOLS_SORT { """ touch ${prefix}.${extension} ${index} - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') - END_VERSIONS + """ } diff --git a/modules/nf-core/samtools/sort/meta.yml b/modules/nf-core/samtools/sort/meta.yml index 4c4010bbb36d..08a6627501d4 100644 --- a/modules/nf-core/samtools/sort/meta.yml +++ b/modules/nf-core/samtools/sort/meta.yml @@ -76,7 +76,6 @@ output: description: Sorted SAM file pattern: "*.{sam}" ontologies: [] - crai: - - meta: type: map @@ -110,13 +109,28 @@ output: description: BAM index file (optional) pattern: "*.bai" ontologies: [] - versions: - - versions.yml: - type: file - description: File containing software versions - pattern: "versions.yml" - ontologies: - - edam: http://edamontology.org/format_3750 # YAML + versions_samtools: + - - ${task.process}: + type: string + description: The process the versions were collected from + - samtools: + type: string + description: The tool name + - samtools version | sed '1!d;s/.* //': + type: string + description: The command used to generate the version of the tool + +topics: + - versions: + - - process: + type: string + description: The process the versions were collected from + - tool: + type: string + description: The tool name + - version: + type: string + description: The version of the tool authors: - "@drpatelh" - "@ewels" diff --git a/modules/nf-core/samtools/sort/tests/main.nf.test b/modules/nf-core/samtools/sort/tests/main.nf.test index fa2778722f53..2696d74cc429 100644 --- a/modules/nf-core/samtools/sort/tests/main.nf.test +++ b/modules/nf-core/samtools/sort/tests/main.nf.test @@ -34,7 +34,7 @@ nextflow_process { { assert snapshot( process.out.bam, process.out.bai, - process.out.versions + process.out.findAll { key, val -> key.startsWith("versions") } ).match()} ) } @@ -66,7 +66,7 @@ nextflow_process { { assert snapshot( process.out.bam, process.out.bai, - process.out.versions + process.out.findAll { key, val -> key.startsWith("versions") } ).match()} ) } @@ -98,7 +98,7 @@ nextflow_process { { assert snapshot( process.out.bam, process.out.csi, - process.out.versions + process.out.findAll { key, val -> key.startsWith("versions") } ).match()} ) } @@ -133,7 +133,7 @@ nextflow_process { { assert snapshot( process.out.bam, process.out.csi.collect { it.collect { it instanceof Map ? it : file(it).name } }, - process.out.versions + process.out.findAll { key, val -> key.startsWith("versions") } ).match()} ) } @@ -168,7 +168,7 @@ nextflow_process { { assert snapshot( process.out.bam, process.out.bai.collect { it.collect { it instanceof Map ? it : file(it).name } }, - process.out.versions + process.out.findAll { key, val -> key.startsWith("versions") } ).match()} ) } @@ -203,7 +203,7 @@ nextflow_process { { assert snapshot( process.out.bam, process.out.csi.collect { it.collect { it instanceof Map ? it : file(it).name } }, - process.out.versions + process.out.findAll { key, val -> key.startsWith("versions") } ).match()} ) } @@ -235,7 +235,7 @@ nextflow_process { { assert snapshot( process.out.cram.collect { it.collect { it instanceof Map ? it : file(it).name } }, process.out.crai.collect { it.collect { it instanceof Map ? it : file(it).name } }, - process.out.versions + process.out.findAll { key, val -> key.startsWith("versions") } ).match()} ) } @@ -265,7 +265,7 @@ nextflow_process { then { assertAll ( { assert process.success }, - { assert snapshot(process.out).match() } + { assert snapshot(process.out.findAll { key, val -> key.startsWith("versions") }).match() } ) } } @@ -296,7 +296,7 @@ nextflow_process { then { assertAll ( { assert process.success }, - { assert snapshot(process.out).match() } + { assert snapshot(process.out.findAll { key, val -> key.startsWith("versions") }).match() } ) } } @@ -325,7 +325,7 @@ nextflow_process { then { assertAll ( { assert process.success }, - { assert snapshot(process.out).match() } + { assert snapshot(process.out.findAll { key, val -> key.startsWith("versions") }).match() } ) } } diff --git a/modules/nf-core/samtools/sort/tests/main.nf.test.snap b/modules/nf-core/samtools/sort/tests/main.nf.test.snap index 473e17450357..4e618fa3f810 100644 --- a/modules/nf-core/samtools/sort/tests/main.nf.test.snap +++ b/modules/nf-core/samtools/sort/tests/main.nf.test.snap @@ -19,80 +19,21 @@ "test.sorted.cram.crai" ] ], - [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ] - ], - "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" - }, - "timestamp": "2025-09-10T14:43:31.395604" - }, - "bam - stub": { - "content": [ { - "0": [ - [ - { - "id": "test", - "single_end": false - }, - "test.sorted.bam:md5,d41d8cd98f00b204e9800998ecf8427e" - ] - ], - "1": [ - - ], - "2": [ - - ], - "3": [ - - ], - "4": [ - - ], - "5": [ - - ], - "6": [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ], - "bai": [ - - ], - "bam": [ + "versions_samtools": [ [ - { - "id": "test", - "single_end": false - }, - "test.sorted.bam:md5,d41d8cd98f00b204e9800998ecf8427e" + "SAMTOOLS_SORT", + "samtools", + "1.22.1" ] - ], - "crai": [ - - ], - "cram": [ - - ], - "csi": [ - - ], - "sam": [ - - ], - "versions": [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" ] } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-09-10T14:43:37.387063" + "timestamp": "2025-10-29T12:47:01.171084" }, "bam_csi_index": { "content": [ @@ -114,15 +55,39 @@ "test.sorted.bam.csi:md5,01394e702c729cb478df914ffaf9f7f8" ] ], - [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ] + { + "versions_samtools": [ + [ + "SAMTOOLS_SORT", + "samtools", + "1.22.1" + ] + ] + } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-09-10T14:43:06.976036" + "timestamp": "2025-10-29T12:46:00.961675" + }, + "bam - stub": { + "content": [ + { + "versions_samtools": [ + [ + "SAMTOOLS_SORT", + "samtools", + "1.22.1" + ] + ] + } + ], + "meta": { + "nf-test": "0.9.3", + "nextflow": "25.10.0" + }, + "timestamp": "2025-10-29T12:47:12.154354" }, "multiple bam bai index": { "content": [ @@ -144,80 +109,39 @@ "test.sorted.bam.bai" ] ], - [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ] + { + "versions_samtools": [ + [ + "SAMTOOLS_SORT", + "samtools", + "1.22.1" + ] + ] + } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-09-10T14:43:18.72271" + "timestamp": "2025-10-29T12:46:25.488622" }, "cram - stub": { "content": [ { - "0": [ - - ], - "1": [ - [ - { - "id": "test", - "single_end": false - }, - "test.sorted.cram:md5,d41d8cd98f00b204e9800998ecf8427e" - ] - ], - "2": [ - - ], - "3": [ - - ], - "4": [ - - ], - "5": [ - - ], - "6": [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ], - "bai": [ - - ], - "bam": [ - - ], - "crai": [ - - ], - "cram": [ + "versions_samtools": [ [ - { - "id": "test", - "single_end": false - }, - "test.sorted.cram:md5,d41d8cd98f00b204e9800998ecf8427e" + "SAMTOOLS_SORT", + "samtools", + "1.22.1" ] - ], - "csi": [ - - ], - "sam": [ - - ], - "versions": [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" ] } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-09-10T14:43:48.734367" + "timestamp": "2025-10-29T12:47:28.485045" }, "multiple bam": { "content": [ @@ -233,80 +157,39 @@ [ ], - [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ] + { + "versions_samtools": [ + [ + "SAMTOOLS_SORT", + "samtools", + "1.22.1" + ] + ] + } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-09-10T14:43:12.989244" + "timestamp": "2025-10-29T12:46:13.168476" }, "multiple bam - stub": { "content": [ { - "0": [ + "versions_samtools": [ [ - { - "id": "test", - "single_end": false - }, - "test.sorted.bam:md5,cd4eb0077f25e9cff395366b8883dd1f" + "SAMTOOLS_SORT", + "samtools", + "1.22.1" ] - ], - "1": [ - - ], - "2": [ - - ], - "3": [ - - ], - "4": [ - - ], - "5": [ - - ], - "6": [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ], - "bai": [ - - ], - "bam": [ - [ - { - "id": "test", - "single_end": false - }, - "test.sorted.bam:md5,cd4eb0077f25e9cff395366b8883dd1f" - ] - ], - "crai": [ - - ], - "cram": [ - - ], - "csi": [ - - ], - "sam": [ - - ], - "versions": [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" ] } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-09-10T14:43:43.196638" + "timestamp": "2025-10-29T12:47:21.628088" }, "bam_no_index": { "content": [ @@ -322,15 +205,21 @@ [ ], - [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ] + { + "versions_samtools": [ + [ + "SAMTOOLS_SORT", + "samtools", + "1.22.1" + ] + ] + } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-09-10T14:42:54.926504" + "timestamp": "2025-10-29T12:45:47.139418" }, "multiple bam csi index": { "content": [ @@ -352,45 +241,21 @@ "test.sorted.bam.csi" ] ], - [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ] - ], - "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" - }, - "timestamp": "2025-09-10T14:43:25.059178" - }, - "bam": { - "content": [ - [ - [ - { - "id": "test", - "single_end": false - }, - "test.sorted.bam:md5,34aa85e86abefe637f7a4a9887f016fc" - ] - ], - [ - [ - { - "id": "test", - "single_end": false - }, - "test.sorted.bam.csi" + { + "versions_samtools": [ + [ + "SAMTOOLS_SORT", + "samtools", + "1.22.1" + ] ] - ], - [ - "versions.yml:md5,2659b187d681241451539d4c53500b9f" - ] + } ], "meta": { - "nf-test": "0.9.0", - "nextflow": "24.09.0" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2024-10-08T11:59:46.372244" + "timestamp": "2025-10-29T12:46:51.5531" }, "bam_bai_index": { "content": [ @@ -412,14 +277,20 @@ "test.sorted.bam.bai:md5,50dd467c169545a4d5d1f709f7e986e0" ] ], - [ - "versions.yml:md5,18e8b3709b62aa2ba61966672eee91b2" - ] + { + "versions_samtools": [ + [ + "SAMTOOLS_SORT", + "samtools", + "1.22.1" + ] + ] + } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-09-10T14:43:00.82974" + "timestamp": "2025-10-29T12:45:52.796936" } } \ No newline at end of file diff --git a/modules/nf-core/shapeit5/phasecommon/meta.yml b/modules/nf-core/shapeit5/phasecommon/meta.yml index b88722bfa694..6ce521ecd955 100644 --- a/modules/nf-core/shapeit5/phasecommon/meta.yml +++ b/modules/nf-core/shapeit5/phasecommon/meta.yml @@ -2,108 +2,108 @@ name: "shapeit5_phasecommon" description: Tool to phase common sites, typically SNP array data, or the first step of WES/WGS data. keywords: - - phasing - - haplotype - - shapeit +- phasing +- haplotype +- shapeit tools: - - "shapeit5": - description: "Fast and accurate method for estimation of haplotypes (phasing)" - homepage: "https://odelaneau.github.io/shapeit5/" - documentation: "https://odelaneau.github.io/shapeit5/docs/documentation" - tool_dev_url: "https://github.com/odelaneau/shapeit5" - doi: "10.1101/2022.10.19.512867 " - licence: ["MIT"] - identifier: biotools:shapeit5 +- "shapeit5": + description: "Fast and accurate method for estimation of haplotypes (phasing)" + homepage: "https://odelaneau.github.io/shapeit5/" + documentation: "https://odelaneau.github.io/shapeit5/docs/documentation" + tool_dev_url: "https://github.com/odelaneau/shapeit5" + doi: "10.1101/2022.10.19.512867 " + licence: ["MIT"] + identifier: biotools:shapeit5 input: +- - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - input: + type: file + description: | + Target dataset in VCF/BCF format defined at all variable positions. + The file could possibly be without GT field (for efficiency reasons a file containing only the positions is recommended). + pattern: "*.{vcf,bcf,vcf.gz,bcf.gz}" + ontologies: [] + - input_index: + type: file + description: Index file of the input VCF/BCF file containing genotype likelihoods. + pattern: "*.{vcf.gz.csi,bcf.gz.csi}" + ontologies: [] + - pedigree: + type: file + description: | + Pedigree information in the following format: offspring father mother. + pattern: "*.{txt, tsv}" + ontologies: [] + - region: + type: string + description: | + Target region, usually a full chromosome (e.g. chr20:1000000-2000000 or chr20). + For chrX, please treat PAR and non-PAR regions as different choromosome in order to avoid mixing ploidy. + pattern: "chrXX:leftBufferPosition-rightBufferPosition" +- - meta2: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - reference: + type: file + description: Reference panel of haplotypes in VCF/BCF format. + pattern: "*.{vcf.gz,bcf.gz}" + ontologies: [] + - reference_index: + type: file + description: Index file of the Reference panel file. + pattern: "*.{vcf.gz.csi,bcf.gz.csi}" + ontologies: [] +- - meta3: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - scaffold: + type: file + description: Scaffold of haplotypes in VCF/BCF format. + pattern: "*.{vcf.gz,bcf.gz}" + ontologies: [] + - scaffold_index: + type: file + description: Index file of the scaffold file. + pattern: "*.{vcf.gz.csi,bcf.gz.csi}" + ontologies: [] +- - meta4: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - map: + type: file + description: File containing the genetic map. + pattern: "*.gmap" + ontologies: [] +output: + phased_variant: - - meta: type: map description: | Groovy Map containing sample information e.g. [ id:'test', single_end:false ] - - input: + - "*.{vcf,bcf,vcf.gz,bcf.gz}": type: file - description: | - Target dataset in VCF/BCF format defined at all variable positions. - The file could possibly be without GT field (for efficiency reasons a file containing only the positions is recommended). + description: Phased variant dataset in VCF/BCF format. pattern: "*.{vcf,bcf,vcf.gz,bcf.gz}" ontologies: [] - - input_index: - type: file - description: Index file of the input VCF/BCF file containing genotype likelihoods. - pattern: "*.{vcf.gz.csi,bcf.gz.csi}" - ontologies: [] - - pedigree: - type: file - description: | - Pedigree information in the following format: offspring father mother. - pattern: "*.{txt, tsv}" - ontologies: [] - - region: - type: string - description: | - Target region, usually a full chromosome (e.g. chr20:1000000-2000000 or chr20). - For chrX, please treat PAR and non-PAR regions as different choromosome in order to avoid mixing ploidy. - pattern: "chrXX:leftBufferPosition-rightBufferPosition" - - - meta2: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - reference: - type: file - description: Reference panel of haplotypes in VCF/BCF format. - pattern: "*.{vcf.gz,bcf.gz}" - ontologies: [] - - reference_index: - type: file - description: Index file of the Reference panel file. - pattern: "*.{vcf.gz.csi,bcf.gz.csi}" - ontologies: [] - - - meta3: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - scaffold: - type: file - description: Scaffold of haplotypes in VCF/BCF format. - pattern: "*.{vcf.gz,bcf.gz}" - ontologies: [] - - scaffold_index: - type: file - description: Index file of the scaffold file. - pattern: "*.{vcf.gz.csi,bcf.gz.csi}" - ontologies: [] - - - meta4: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - map: - type: file - description: File containing the genetic map. - pattern: "*.gmap" - ontologies: [] -output: - phased_variant: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - "*.{vcf,bcf,vcf.gz,bcf.gz}": - type: file - description: Phased variant dataset in VCF/BCF format. - pattern: "*.{vcf,bcf,vcf.gz,bcf.gz}" - ontologies: [] versions: - - versions.yml: - type: file - description: File containing software versions - pattern: "versions.yml" - ontologies: - - edam: http://edamontology.org/format_3750 # YAML + - versions.yml: + type: file + description: File containing software versions + pattern: "versions.yml" + ontologies: + - edam: http://edamontology.org/format_3750 # YAML authors: - - "@LouisLeNezet" +- "@LouisLeNezet" maintainers: - - "@LouisLeNezet" +- "@LouisLeNezet"