pub fn new() -> Config {
        let app = App::new(NAME)
            .version(VERSION)
            .author("Brian Martin <bmartin@twitter.com>")
            .about("High-Resolution Systems Performance Telemetry")
            .arg(
                Arg::with_name("config")
                    .long("config")
                    .value_name("FILE")
                    .help("TOML config file")
                    .takes_value(true),
            )
            .arg(
                Arg::with_name("verbose")
                    .short("v")
                    .long("verbose")
                    .help("Increase verbosity by one level. Can be used more than once")
                    .multiple(true),
            );

        let matches = app.get_matches();

        let mut config = if let Some(file) = matches.value_of("config") {
            Config::load_from_file(file)
        } else {
            println!("NOTE: using builtin base configuration");
            Default::default()
        };

        config
            .general
            .set_logging(match matches.occurrences_of("verbose") {
                0 => Level::Info,
                1 => Level::Debug,
                _ => Level::Trace,
            });

        config
    }
/// parse command line options and return `Config`
parse command line options and return `Config`
parse command line options and return ` Config `
pub fn new() -> Config {
        let app = App::new(NAME)
            .version(VERSION)
            .author("Brian Martin <bmartin@twitter.com>")
            .about("High-Resolution Systems Performance Telemetry")
            .arg(
                Arg::with_name("config")
                    .long("config")
                    .value_name("FILE")
                    .help("TOML config file")
                    .takes_value(true),
            )
            .arg(
                Arg::with_name("verbose")
                    .short("v")
                    .long("verbose")
                    .help("Increase verbosity by one level. Can be used more than once")
                    .multiple(true),
            );
        let matches = app.get_matches();
        let mut config = if let Some(file) = matches.value_of("config") {
            Config::load_from_file(file)
        } else {
            println!("NOTE: using builtin base configuration");
            Default::default()
        };
        config
            .general
            .set_logging(match matches.occurrences_of("verbose") {
                0 => Level::Info,
                1 => Level::Debug,
                _ => Level::Trace,
            });
        config
    }
pub fn new ( ) -> Config { let app = App :: new ( NAME ) . version ( VERSION ) . author ( " " ) . about ( " " ) . arg ( Arg :: with_name ( " " ) . long ( " " ) . value_name ( " " ) . help ( " " ) . takes_value ( true ) , ) . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) . multiple ( true ) , ) ; let matches = app . get_matches ( ) ; let mut config = if let Some ( file ) = matches . value_of ( " " ) { Config :: load_from_file ( file ) } else { println ! ( " " ) ; Default :: default ( ) } ; config . general . set_logging ( match matches . occurrences_of ( " " ) { 0 => Level :: Info , 1 => Level :: Debug , _ => Level :: Trace , } ) ; config }
parse command line options and return `Config`
parse command line options and return ` Config `