paprika 0.0.4

Paprika is a command line parser
Documentation
  • Coverage
  • 0%
    0 out of 5 items documented0 out of 3 items with examples
  • Size
  • Source code size: 8.76 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 648.18 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Links
  • tak0g/paprika
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • tak0g

PAPRIKA

Build Status

PAPRIKA is Command Line Parser like a toy.
PAPRIKA is a product for learning Rust and version control.
If you need a good command line parser, You should use Clap instead of PAPRIKA.

[dependencies]
paprika = "*"
extern crate paprika;

use paprika::{App, Ops};

use std::process;

fn main() {

    let mut app = App::new();
    let ver = Ops::new()
                .short("v")
                .long("version")
                .description("version");
    app.add_ops(ver);

    app.parse();
    if app.has_ops("version") {
        println!("version {}", env!("CARGO_PKG_VERSION"));
        process::exit(0);
    }

}
cargo run --example example -- -v
cargo run --example get_value --  --name="YOUR NAME"