diff --git a/src/cli.yaml b/src/cli.yaml index f7900e7d..2cf183eb 100644 --- a/src/cli.yaml +++ b/src/cli.yaml @@ -1,7 +1,3 @@ -name: Rust-Bio-Tools -author: Johannes Köster -about: A set of ultra-fast command line utilities for bioinformatics tasks based on Rust-Bio. - settings: - SubcommandRequired @@ -41,7 +37,6 @@ subcommands: required: true help: File with list of record IDs to remove, one per line. - - bam-depth: about: | Print depth of BAM or CRAM file at given positions from STDIN (tab separated: chrom, pos). @@ -77,7 +72,7 @@ subcommands: long: incl-flags short: i value_name: INT - help: "Skip reads with mask bits unset []." + help: "Skip reads with mask bits unset []." - exclude-flags: long: excl-flags short: e @@ -168,32 +163,33 @@ subcommands: author: Johannes Köster , Jan Forster - vcf-annotate-dgidb: - about: | - Looks for interacting drugs in DGIdb and annotates them for every gene in every record. + about: | + Looks for interacting drugs in DGIdb and annotates them for every gene in every record. - Example: - rbt vcf-annotate-dgidb input.vcf > output.vcf - args: - - vcf: - required: true - help: VCF/BCF file to be extended by dgidb drug entries - - api-path: - long: api-path - short: p - default_value: http://dgidb.org/api/v2/interactions.json?genes= - help: url prefix for requesting interaction drugs by gene names. - - field: - long: field - short: f - default_value: dgiDB_drugs - help: Info field name to be used for annotation. - - genes-per-request: - long: genes-per-request - short: g - default_value: "1000" - help: Number of genes to submit per api request. A lower value increases the number of api requests in return. - Too many requests could be rejected by the DGIdb server. - author: Felix Mölder + Example: + rbt vcf-annotate-dgidb input.vcf > output.vcf + args: + - vcf: + required: true + help: VCF/BCF file to be extended by dgidb drug entries + - api-path: + long: api-path + short: p + default_value: http://dgidb.org/api/v2/interactions.json?genes= + help: url prefix for requesting interaction drugs by gene names. + - field: + long: field + short: f + default_value: dgiDB_drugs + help: Info field name to be used for annotation. + - genes-per-request: + long: genes-per-request + short: g + default_value: "1000" + help: + Number of genes to submit per api request. A lower value increases the number of api requests in return. + Too many requests could be rejected by the DGIdb server. + author: Felix Mölder - call-consensus-reads: about: | @@ -226,56 +222,56 @@ subcommands: {n} author: Johannes Köster , Henning Timm , Felix Mölder args: - - fq1: - required: true - help: Input FASTQ file with forward reads. - - fq2: - required: true - help: Input FASTQ file with reverse reads. - - consensus-fq1: - required: true - help: Output FASTQ file with forward reads. - - consensus-fq2: - required: true - help: Output FASTQ file with reverse reads. - - consensus-fq3: - requires: [insert-size, std-dev] - help: Output FASTQ file for overlapping consensus reads (Required for calculating overlapping consensus only) - - max-umi-dist: - long: max-umi-dist - short: d - default_value: "1" - help: Maximum hamming distance between the UMIs of any pair of reads in the same cluster. - - umi-len: - long: umi-len - short: l - default_value: "8" - help: Length of UMI in read. - - max-seq-dist: - long: max-seq-dist - short: D - possible_values: ["1", "2", "3", "4", "5", "6", "7", "8"] - default_value: "2" - help: Maximum hamming distance between the sequences of any pair of reads in the same cluster. - - umi-on-reverse: - long: umi-on-reverse - short: u - help: Set if UMI is on reverse read - - verbose-read-names: - long: verbose-read-names - help: Add list of reads that were merged for each consensus read. Note that this can yield very long FASTQ name lines which cannot be handled by some tools. - - insert-size: - long: insert-size - short: i - takes_value: true - requires: [consensus-fq3, std-dev] - help: Expected insert size of sequenced fragment (Required for calculating overlapping consensus only) - - std-dev: - long: std-dev - short: s - takes_value: true - requires: [consensus-fq3, insert-size] - help: Standard deviation of expected insert size. Defines search space of the most likely overlap. (Required for calculating overlapping consensus only) + - fq1: + required: true + help: Input FASTQ file with forward reads. + - fq2: + required: true + help: Input FASTQ file with reverse reads. + - consensus-fq1: + required: true + help: Output FASTQ file with forward reads. + - consensus-fq2: + required: true + help: Output FASTQ file with reverse reads. + - consensus-fq3: + requires: [insert-size, std-dev] + help: Output FASTQ file for overlapping consensus reads (Required for calculating overlapping consensus only) + - max-umi-dist: + long: max-umi-dist + short: d + default_value: "1" + help: Maximum hamming distance between the UMIs of any pair of reads in the same cluster. + - umi-len: + long: umi-len + short: l + default_value: "8" + help: Length of UMI in read. + - max-seq-dist: + long: max-seq-dist + short: D + possible_values: ["1", "2", "3", "4", "5", "6", "7", "8"] + default_value: "2" + help: Maximum hamming distance between the sequences of any pair of reads in the same cluster. + - umi-on-reverse: + long: umi-on-reverse + short: u + help: Set if UMI is on reverse read + - verbose-read-names: + long: verbose-read-names + help: Add list of reads that were merged for each consensus read. Note that this can yield very long FASTQ name lines which cannot be handled by some tools. + - insert-size: + long: insert-size + short: i + takes_value: true + requires: [consensus-fq3, std-dev] + help: Expected insert size of sequenced fragment (Required for calculating overlapping consensus only) + - std-dev: + long: std-dev + short: s + takes_value: true + requires: [consensus-fq3, insert-size] + help: Standard deviation of expected insert size. Defines search space of the most likely overlap. (Required for calculating overlapping consensus only) - bam: about: | Tool to remove PCR duplicates from BAM file. @@ -304,5 +300,3 @@ subcommands: - verbose-read-names: long: verbose-read-names help: Add list of reads that were merged for each consensus read. Note that this can yield very long FASTQ name lines which cannot be handled by some tools. - - diff --git a/src/main.rs b/src/main.rs index e7c8c650..d66391d0 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,4 +1,6 @@ //! Documentation for Rust Bio Tools +#[macro_use] +extern crate clap; use clap::{load_yaml, value_t}; use log::LevelFilter; @@ -15,7 +17,10 @@ pub mod fastq; fn main() -> Result<(), Box> { let yaml = load_yaml!("cli.yaml"); let matches = App::from_yaml(yaml) - .version(env!("CARGO_PKG_VERSION")) + .name(crate_name!()) + .author(crate_authors!()) + .version(crate_version!()) + .about(crate_description!()) .get_matches(); fern::Dispatch::new()