feat: init commit
This commit is contained in:
18
src/main.rs
Normal file
18
src/main.rs
Normal file
@@ -0,0 +1,18 @@
|
||||
#[macro_use] extern crate rust_util;
|
||||
|
||||
use clap::{App, Arg};
|
||||
|
||||
fn main() {
|
||||
let matches = App::new(env!("CARGO_PKG_NAME"))
|
||||
.version(env!("CARGO_PKG_VERSION"))
|
||||
.author(env!("CARGO_PKG_AUTHORS"))
|
||||
.about(env!("CARGO_PKG_DESCRIPTION"))
|
||||
.arg(Arg::with_name("FILE").required(true).index(1).help("plist file name"))
|
||||
.get_matches();
|
||||
|
||||
let file = matches.value_of("FILE").unwrap();
|
||||
let plist_value = plist::from_file(file).unwrap_or_else(|e| {
|
||||
failure_and_exit!("Read plist file: {}, failed: {}", file, e);
|
||||
});
|
||||
// println!(plist::to_writer_xml())
|
||||
}
|
||||
Reference in New Issue
Block a user