From aa24e65510b7e4f30aa07579b4cf20d2a44864ee Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Mon, 28 Aug 2023 17:40:50 -0500 Subject: [PATCH 1/4] feat: Add exists to schema --- nextflow_schema.json | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/nextflow_schema.json b/nextflow_schema.json index 5f6a0865..d7f5a024 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -105,6 +105,8 @@ "fasta_index": { "type": "string", "format": "file-path", + "exists": true, + "mimetype": "text/plain", "description": "Path to Fasta index file.", "help_text": "The FASTA index file (`.fa.fai`) is only needed when using the bwa_meth aligner. It is used by MethylDackel. If using Bismark this parameter is ignored.", "fa_icon": "fas fa-bookmark" @@ -112,12 +114,14 @@ "bismark_index": { "type": "string", "format": "directory-path", + "exists": true, "description": "Path to a directory containing a Bismark reference index.", "fa_icon": "fas fa-dot-circle" }, "bwa_meth_index": { "type": "string", "format": "directory-path", + "exists": true, "description": "bwameth index filename base", "help_text": "Directory for a bwa-meth genome reference index. Only used when using the bwa-meth aligner.\n\nNote that this is not a complete path, but the directory containing the reference. For example, if you have file paths such as `/path/to/ref/genome.fa.bwameth.c2t.bwt`, you should specify `/path/to/ref/`.", "fa_icon": "far fa-dot-circle" @@ -339,6 +343,8 @@ }, "known_splices": { "type": "string", + "format": "file-path", + "exists": true, "description": "Supply a .gtf file containing known splice sites (bismark_hisat only).", "help_text": "Specify to run Bismark with the `--known-splicesite-infile` flag to run splice-aware alignment using HISAT2. A `.gtf` file has to be provided from which a list of known splicesites is created by the pipeline\n\n> NB: This only works when using the `bismark_hisat` aligner with `--align`", "fa_icon": "fas fa-barcode" @@ -403,7 +409,9 @@ "default": "", "properties": { "bamqc_regions_file": { - "type": "string", + "format": "file-path", + "exists": true, + "mimetype": "text/plain", "description": "A GFF or BED file containing the target regions which will be passed to Qualimap/Bamqc.", "help_text": "Setting this option could be useful if you want calculate coverage stats over a list of regions, i.e. for targeted methylation sequencing data." } From f795c9a65bcd45f08b4c4c06c7079ca9c36cc05b Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Mon, 28 Aug 2023 17:42:21 -0500 Subject: [PATCH 2/4] feat: Add patterns to schema --- nextflow_schema.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/nextflow_schema.json b/nextflow_schema.json index d7f5a024..3f1d73da 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -98,7 +98,7 @@ "format": "file-path", "exists": true, "mimetype": "text/plain", - "pattern": "^\\S+\\.fn?a(sta)?$", + "pattern": "^\\S+\\.fn?a(sta)?(\\.gz)?$", "description": "Path to FASTA genome file", "help_text": "If you have no genome reference available, the pipeline can build one using a FASTA file. This requires additional time and resources, so it's better to use a pre-build index if possible. You can use the command line option `--save_reference` to keep the generated references so that they can be added to your config and used again in the future. If aligner is Bismark and bismark_index is specified, this parameter is ignored." }, @@ -107,6 +107,7 @@ "format": "file-path", "exists": true, "mimetype": "text/plain", + "pattern": "^\\S+\\.fn?a(sta)?(\\.gz)?$", "description": "Path to Fasta index file.", "help_text": "The FASTA index file (`.fa.fai`) is only needed when using the bwa_meth aligner. It is used by MethylDackel. If using Bismark this parameter is ignored.", "fa_icon": "fas fa-bookmark" @@ -345,6 +346,7 @@ "type": "string", "format": "file-path", "exists": true, + "pattern": "^\\S+\\.gtf(\\.gz)?$", "description": "Supply a .gtf file containing known splice sites (bismark_hisat only).", "help_text": "Specify to run Bismark with the `--known-splicesite-infile` flag to run splice-aware alignment using HISAT2. A `.gtf` file has to be provided from which a list of known splicesites is created by the pipeline\n\n> NB: This only works when using the `bismark_hisat` aligner with `--align`", "fa_icon": "fas fa-barcode" @@ -412,6 +414,7 @@ "format": "file-path", "exists": true, "mimetype": "text/plain", + "pattern": "^\\S+\\.gff|\\.bed(\\.gz)?$", "description": "A GFF or BED file containing the target regions which will be passed to Qualimap/Bamqc.", "help_text": "Setting this option could be useful if you want calculate coverage stats over a list of regions, i.e. for targeted methylation sequencing data." } From 93cd17c97aa02deb37fcbce7a79164a22ceb9c3d Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Tue, 17 Oct 2023 10:42:56 +0200 Subject: [PATCH 3/4] fix(schema): Update formats and exists And the fasta index regex --- nextflow_schema.json | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/nextflow_schema.json b/nextflow_schema.json index 3f1d73da..a87bcb95 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -107,22 +107,20 @@ "format": "file-path", "exists": true, "mimetype": "text/plain", - "pattern": "^\\S+\\.fn?a(sta)?(\\.gz)?$", + "pattern": "^\\S+\\.fn?a(sta)?.fai$", "description": "Path to Fasta index file.", "help_text": "The FASTA index file (`.fa.fai`) is only needed when using the bwa_meth aligner. It is used by MethylDackel. If using Bismark this parameter is ignored.", "fa_icon": "fas fa-bookmark" }, "bismark_index": { "type": "string", - "format": "directory-path", - "exists": true, + "format": "path", "description": "Path to a directory containing a Bismark reference index.", "fa_icon": "fas fa-dot-circle" }, "bwa_meth_index": { "type": "string", - "format": "directory-path", - "exists": true, + "format": "path", "description": "bwameth index filename base", "help_text": "Directory for a bwa-meth genome reference index. Only used when using the bwa-meth aligner.\n\nNote that this is not a complete path, but the directory containing the reference. For example, if you have file paths such as `/path/to/ref/genome.fa.bwameth.c2t.bwt`, you should specify `/path/to/ref/`.", "fa_icon": "far fa-dot-circle" From 3d63bca5aedb3abf5eac1058c48192348a91c368 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Mon, 28 Aug 2023 17:49:40 -0500 Subject: [PATCH 4/4] chore: Update CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8fab234f..a5c85b10 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ - Removes problematic `-m` memory assignment for samtools sort [#81](https://github.com/nf-core/methylseq/issues/81) - Use `fromSamplesheet` from nf-validation [#341](https://github.com/nf-core/methylseq/pull/341) - Update Maintainers and add CODEOWNERS [#345](https://github.com/nf-core/methylseq/pull/345) +- Update schema to utilize exists and add more patterns [#342](https://github.com/nf-core/methylseq/pull/342) ### Bug fixes & refactoring