-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #574 from nf-core/change-download-ci
Refactor
- Loading branch information
Showing
16 changed files
with
151 additions
and
126 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
/* | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
Config file for defining DSL2 per module options and publishing paths | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
Available keys to override module options: | ||
ext.args = Additional arguments appended to command in module. | ||
ext.args2 = Second set of arguments appended to command in module (multi-tool modules). | ||
ext.args3 = Third set of arguments appended to command in module (multi-tool modules). | ||
ext.prefix = File name prefix for output files. | ||
ext.when = Conditional clause | ||
---------------------------------------------------------------------------------------- | ||
*/ | ||
|
||
// | ||
// Repeat expansion calling options | ||
// | ||
|
||
process { | ||
|
||
withName: '.*ANNOTATE_REPEAT_EXPANSIONS:STRANGER' { | ||
ext.prefix = { "${meta.id}_stranger" } | ||
} | ||
|
||
withName: '.*ANNOTATE_REPEAT_EXPANSIONS:COMPRESS_STRANGER' { | ||
ext.prefix = { "${meta.id}_repeat_expansion_stranger" } | ||
ext.args = '--output-type z' | ||
publishDir = [ | ||
path: { "${params.outdir}/repeat_expansions" }, | ||
mode: params.publish_dir_mode, | ||
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, | ||
] | ||
} | ||
|
||
withName: '.*ANNOTATE_REPEAT_EXPANSIONS:INDEX_STRANGER' { | ||
publishDir = [ | ||
path: { "${params.outdir}/repeat_expansions" }, | ||
mode: params.publish_dir_mode, | ||
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
// | ||
// Annotate repeat expansions | ||
// | ||
|
||
include { BCFTOOLS_VIEW as COMPRESS_STRANGER } from '../../modules/nf-core/bcftools/view/main' | ||
include { STRANGER } from '../../modules/nf-core/stranger/main' | ||
include { TABIX_TABIX as INDEX_STRANGER } from '../../modules/nf-core/tabix/tabix/main' | ||
|
||
workflow ANNOTATE_REPEAT_EXPANSIONS { | ||
take: | ||
ch_variant_catalog // channel: [mandatory] [ path(variant_catalog.json) ] | ||
ch_vcf // channel: [mandatory] [ val(meta), path(vcf) ] | ||
|
||
main: | ||
ch_versions = Channel.empty() | ||
|
||
// Annotate, compress and index | ||
STRANGER ( ch_vcf, ch_variant_catalog ) | ||
COMPRESS_STRANGER ( | ||
STRANGER.out.vcf.map{ meta, vcf -> [meta, vcf, [] ]}, | ||
[], [], [] | ||
) | ||
INDEX_STRANGER ( COMPRESS_STRANGER.out.vcf ) | ||
|
||
ch_vcf_idx = COMPRESS_STRANGER.out.vcf.join(INDEX_STRANGER.out.tbi, failOnMismatch:true, failOnDuplicate:true) | ||
|
||
ch_versions = ch_versions.mix(STRANGER.out.versions.first()) | ||
ch_versions = ch_versions.mix(COMPRESS_STRANGER.out.versions.first()) | ||
ch_versions = ch_versions.mix(INDEX_STRANGER.out.versions.first()) | ||
|
||
emit: | ||
vcf = ch_vcf_idx // channel: [ val(meta), path(vcf), path(tbi) ] | ||
versions = ch_versions // channel: [ path(versions.yml) ] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.