Switch to a command-line API closer to TaskWarrior
* Use a parser (rather than clap) to process the command line * Outline some generic support for filtering, reporting, modifying, etc. * Break argument parsing strictly from invocation, to allow independent testing
This commit is contained in:
12
cli/src/macros.rs
Normal file
12
cli/src/macros.rs
Normal file
@@ -0,0 +1,12 @@
|
||||
#![macro_use]
|
||||
|
||||
/// create a &[&str] from vec notation
|
||||
#[cfg(test)]
|
||||
macro_rules! argv {
|
||||
() => (
|
||||
&[][..]
|
||||
);
|
||||
($($x:expr),* $(,)?) => (
|
||||
&[$($x),*][..]
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user