Add structopt
Co-authored-by: Elias Schriefer
This commit is contained in:
16
src/main.rs
16
src/main.rs
@@ -1,3 +1,15 @@
|
||||
fn main() {
|
||||
println!("Hello, world!");
|
||||
use structopt::StructOpt;
|
||||
use std::path::PathBuf;
|
||||
|
||||
#[derive(Debug, StructOpt)]
|
||||
struct Options {
|
||||
#[structopt(short, long, default_value = "/etc/noise-server/config.toml")]
|
||||
config: PathBuf,
|
||||
|
||||
#[structopt(short, long, default_value = "/var/lib/noise-server/noise-server.sqlite")]
|
||||
database_path: PathBuf,
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let options = Options::from_args();
|
||||
}
|
||||
|
Reference in New Issue
Block a user