Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion modules/nf-core/vg/construct/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ channels:
- conda-forge
- bioconda
dependencies:
- bioconda::vg=1.45.0
- bioconda::vg=1.73.0
16 changes: 3 additions & 13 deletions modules/nf-core/vg/construct/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ process VG_CONSTRUCT {

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine in ['singularity', 'apptainer'] && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/vg:1.45.0--h9ee0642_0':
'quay.io/biocontainers/vg:1.45.0--h9ee0642_0' }"
'https://depot.galaxyproject.org/singularity/vg:1.73.0--h9ee0642_0':
'quay.io/biocontainers/vg:1.73.0--h9ee0642_0' }"

input:
tuple val(meta), path(input), path(tbis), path(insertions_fasta)
Expand All @@ -14,7 +14,7 @@ process VG_CONSTRUCT {

output:
tuple val(meta), path("*.vg") , emit: graph
path "versions.yml" , emit: versions
tuple val("${task.process}"), val('vg'), eval("vg 2>&1 | sed -n 's/.*version v\\([0-9.]*\\).*/\\1/p'"), topic: versions, emit: versions_vg

when:
task.ext.when == null || task.ext.when
Expand All @@ -38,21 +38,11 @@ process VG_CONSTRUCT {
${input_files} \\
${insertions} \\
> ${prefix}.vg

cat <<-END_VERSIONS > versions.yml
"${task.process}":
vg: \$(echo \$(vg 2>&1 | head -n 1 | sed 's/vg: variation graph tool, version v//;s/ ".*"//' ))
END_VERSIONS
"""

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
"""
touch ${prefix}.vg

cat <<-END_VERSIONS > versions.yml
"${task.process}":
vg: \$(echo \$(vg 2>&1 | head -n 1 | sed 's/vg: variation graph tool, version v//;s/ ".*"//' ))
END_VERSIONS
"""
}
41 changes: 28 additions & 13 deletions modules/nf-core/vg/construct/meta.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: "vg_construct"
description: Constructs a graph from a reference and variant calls or a multiple sequence
alignment file
description: Constructs a graph from a reference and variant calls or a multiple
sequence alignment file
keywords:
- vg
- graph
Expand All @@ -15,7 +15,8 @@ tools:
and variant calling methods.
homepage: https://github.com/vgteam/vg
documentation: https://github.com/vgteam/vg/wiki
licence: ["MIT"]
licence:
- "MIT"
identifier: ""
input:
- - meta:
Expand All @@ -34,8 +35,8 @@ input:
pattern: "*.tbi"
- insertions_fasta:
type: file
description: A FASTA file containing insertion sequences (referred to in the
VCF file(s))
description: A FASTA file containing insertion sequences (referred to in
the VCF file(s))
pattern: "*.{fa,fasta,fna}"
ontologies: []
- - meta2:
Expand All @@ -45,8 +46,8 @@ input:
e.g. [ id:'test', single_end:false ]
- fasta:
type: file
description: The reference FASTA file (cannot be used in combination with `msa`,
but is required when using `vcfs`)
description: The reference FASTA file (cannot be used in combination with
`msa`, but is required when using `vcfs`)
pattern: "*.{fa,fasta,fna}"
ontologies: []
- - meta3:
Expand All @@ -71,13 +72,27 @@ output:
description: The constructed graph
pattern: "*.vg"
ontologies: []
versions_vg:
- - ${task.process}:
type: string
description: The name of the process
- vg:
type: string
description: The name of the tool
- vg 2>&1 | sed -n 's/.*version v\([0-9.]*\).*/\1/p':
type: eval
description: The expression to obtain the version of the tool
topics:
versions:
- versions.yml:
type: file
description: File containing software versions
pattern: "versions.yml"
ontologies:
- edam: http://edamontology.org/format_3750 # YAML
- - ${task.process}:
type: string
description: The name of the process
- vg:
type: string
description: The name of the tool
- vg 2>&1 | sed -n 's/.*version v\([0-9.]*\).*/\1/p':
type: eval
description: The expression to obtain the version of the tool
authors:
- "@nvnieuwk"
maintainers:
Expand Down
8 changes: 4 additions & 4 deletions modules/nf-core/vg/construct/tests/main.nf.test
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ nextflow_process {
then {
assertAll(
{ assert process.success },
{ assert snapshot(process.out).match() }
{ assert snapshot(sanitizeOutput(process.out, unstableKeys: [])).match() }
)
}
}
Expand All @@ -63,7 +63,7 @@ nextflow_process {
then {
assertAll(
{ assert process.success },
{ assert snapshot(process.out).match() }
{ assert snapshot(sanitizeOutput(process.out, unstableKeys: [])).match() }
)
}
}
Expand Down Expand Up @@ -95,7 +95,7 @@ nextflow_process {
then {
assertAll(
{ assert process.success },
{ assert snapshot(process.out).match() }
{ assert snapshot(sanitizeOutput(process.out, unstableKeys: [])).match() }
)
}
}
Expand Down Expand Up @@ -127,7 +127,7 @@ nextflow_process {
then {
assertAll(
{ assert process.success },
{ assert snapshot(process.out).match() }
{ assert snapshot(sanitizeOutput(process.out, unstableKeys: [])).match() }
)
}
}
Expand Down
104 changes: 38 additions & 66 deletions modules/nf-core/vg/construct/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,133 +2,105 @@
"test-vg-construct-insertions-fasta-vcf-stub": {
"content": [
{
"0": [
"graph": [
[
{
"id": "test"
},
"test.vg:md5,d41d8cd98f00b204e9800998ecf8427e"
]
],
"1": [
"versions.yml:md5,9c0daae7e404b6c57cc9516eeb2df066"
],
"graph": [
"versions_vg": [
[
{
"id": "test"
},
"test.vg:md5,d41d8cd98f00b204e9800998ecf8427e"
"VG_CONSTRUCT",
"vg",
"1.73.0"
]
],
"versions": [
"versions.yml:md5,9c0daae7e404b6c57cc9516eeb2df066"
]
}
],
"timestamp": "2026-06-13T09:06:11.213034116",
"meta": {
"nf-test": "0.8.4",
"nextflow": "24.04.4"
},
"timestamp": "2024-08-30T11:32:27.550644"
"nf-test": "0.9.5",
"nextflow": "26.04.0"
}
},
"test-vg-construct-insertions-fasta-vcf": {
"content": [
{
"0": [
"graph": [
[
{
"id": "test"
},
"test.vg:md5,57782ed149d3ba8fef2cc112f49f5a37"
"test.vg:md5,faa32812ad54f50985da3a082ee61887"
]
],
"1": [
"versions.yml:md5,9c0daae7e404b6c57cc9516eeb2df066"
],
"graph": [
"versions_vg": [
[
{
"id": "test"
},
"test.vg:md5,57782ed149d3ba8fef2cc112f49f5a37"
"VG_CONSTRUCT",
"vg",
"1.73.0"
]
],
"versions": [
"versions.yml:md5,9c0daae7e404b6c57cc9516eeb2df066"
]
}
],
"timestamp": "2026-06-13T09:06:04.557473372",
"meta": {
"nf-test": "0.8.4",
"nextflow": "24.04.4"
},
"timestamp": "2024-08-30T11:32:14.964667"
"nf-test": "0.9.5",
"nextflow": "26.04.0"
}
},
"test-vg-construct-vcf": {
"content": [
{
"0": [
"graph": [
[
{
"id": "test"
},
"test.vg:md5,57782ed149d3ba8fef2cc112f49f5a37"
"test.vg:md5,faa32812ad54f50985da3a082ee61887"
]
],
"1": [
"versions.yml:md5,9c0daae7e404b6c57cc9516eeb2df066"
],
"graph": [
"versions_vg": [
[
{
"id": "test"
},
"test.vg:md5,57782ed149d3ba8fef2cc112f49f5a37"
"VG_CONSTRUCT",
"vg",
"1.73.0"
]
],
"versions": [
"versions.yml:md5,9c0daae7e404b6c57cc9516eeb2df066"
]
}
],
"timestamp": "2026-06-13T09:05:46.30677193",
"meta": {
"nf-test": "0.8.4",
"nextflow": "24.04.4"
},
"timestamp": "2024-08-30T11:31:46.999392"
"nf-test": "0.9.5",
"nextflow": "26.04.0"
}
},
"test-vg-construct-msa": {
"content": [
{
"0": [
"graph": [
[
{
"id": "test"
},
"test.vg:md5,e93a644ebe4858f0f1f13cd37d22c157"
]
],
"1": [
"versions.yml:md5,9c0daae7e404b6c57cc9516eeb2df066"
],
"graph": [
"versions_vg": [
[
{
"id": "test"
},
"test.vg:md5,e93a644ebe4858f0f1f13cd37d22c157"
"VG_CONSTRUCT",
"vg",
"1.73.0"
]
],
"versions": [
"versions.yml:md5,9c0daae7e404b6c57cc9516eeb2df066"
]
}
],
"timestamp": "2026-06-13T09:05:53.883929733",
"meta": {
"nf-test": "0.8.4",
"nextflow": "24.04.4"
},
"timestamp": "2024-08-30T11:31:59.359779"
"nf-test": "0.9.5",
"nextflow": "26.04.0"
}
}
}
2 changes: 1 addition & 1 deletion modules/nf-core/vg/deconstruct/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ channels:
- conda-forge
- bioconda
dependencies:
- bioconda::vg=1.43.0
- bioconda::vg=1.73.0
15 changes: 8 additions & 7 deletions modules/nf-core/vg/deconstruct/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ process VG_DECONSTRUCT {

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine in ['singularity', 'apptainer'] && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/vg:1.43.0--h9ee0642_0' :
'quay.io/biocontainers/vg:1.43.0--h9ee0642_0' }"
'https://depot.galaxyproject.org/singularity/vg:1.73.0--h9ee0642_0' :
'quay.io/biocontainers/vg:1.73.0--h9ee0642_0' }"

input:
tuple val(meta), path(gfa)
Expand All @@ -14,7 +14,7 @@ process VG_DECONSTRUCT {

output:
tuple val(meta), path("*.vcf"), emit: vcf
path "versions.yml" , emit: versions
tuple val("${task.process}"), val('vg'), eval("vg 2>&1 | sed -n 's/.*version v\\([0-9.]*\\).*/\\1/p'"), topic: versions, emit: versions_vg

when:
task.ext.when == null || task.ext.when
Expand All @@ -31,10 +31,11 @@ process VG_DECONSTRUCT {
$snarls \\
$gbwt_arg \\
$gfa > ${prefix}.vcf
"""

cat <<-END_VERSIONS > versions.yml
"${task.process}":
vg: \$(vg version 2>&1 | grep -o 'vg .*' | cut -f3 -d ' ' | cut -f2 -d 'v')
END_VERSIONS
stub:
def prefix = task.ext.prefix ?: "${meta.id}"
"""
touch ${prefix}.vcf
"""
}
Loading