-
Notifications
You must be signed in to change notification settings - Fork 2
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 #102 from noamteyssier/100-add-vcf-centric-commands
100 add vcf centric commands
- Loading branch information
Showing
27 changed files
with
13,954 additions
and
48 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
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,8 @@ | ||
use super::FilterArgs; | ||
use clap::Parser; | ||
|
||
#[derive(Parser, Debug, Clone)] | ||
pub enum BcfCommand { | ||
/// Filter BCF records based on overlap criteria to other regions | ||
Filter(FilterArgs), | ||
} |
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,33 @@ | ||
use crate::cli::{outputs::VcfOutput, MixedInputVcf, OverlapPredicates}; | ||
|
||
use clap::Parser; | ||
|
||
#[derive(Parser, Debug, Clone)] | ||
pub struct FilterArgs { | ||
#[clap(flatten)] | ||
pub inputs: MixedInputVcf, | ||
|
||
#[clap(flatten)] | ||
pub params: FilterParams, | ||
|
||
#[clap(flatten)] | ||
pub output: VcfOutput, | ||
} | ||
|
||
#[derive(Parser, Debug, Clone)] | ||
#[clap(next_help_heading = "Parameters")] | ||
pub struct FilterParams { | ||
#[clap(flatten)] | ||
pub overlap_predicates: OverlapPredicates, | ||
|
||
#[clap(flatten)] | ||
pub output_predicates: OutputPredicates, | ||
} | ||
|
||
#[derive(Parser, Debug, Clone)] | ||
#[clap(next_help_heading = "Output Predicates")] | ||
pub struct OutputPredicates { | ||
/// Only return the records from a that DON'T overlap with b | ||
#[clap(short = 'v', long)] | ||
pub invert: bool, | ||
} |
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,5 @@ | ||
mod commands; | ||
mod filter; | ||
|
||
pub use commands::BcfCommand; | ||
pub use filter::{FilterArgs, FilterParams}; |
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
Oops, something went wrong.