Added descriptions [CI SKIP]

This commit is contained in:
shimunn 2019-04-03 16:57:00 +02:00
parent 6a13b27c19
commit d1daf3be00

View File

@ -4,14 +4,16 @@ use structopt::StructOpt;
#[derive(StructOpt, Debug)]
#[structopt(name = "event-gen")]
pub struct Opts {
///Time after which a client is considered as offline
#[structopt(
short = "t",
long = "timeout",
default_value = "120",
default_value = "115",
env = "WG_EVENT_TIMEOUT"
)]
pub timeout: u64,
///Interval after which Wireguard will be polled for updates
#[structopt(
short = "p",
long = "poll-interval",
@ -20,6 +22,7 @@ pub struct Opts {
)]
pub poll: u64,
///Programm to run when an event has fired
#[structopt(
short = "e",
long = "event-handler",
@ -28,12 +31,15 @@ pub struct Opts {
)]
pub events: Option<PathBuf>,
///Don't exit on API errors
#[structopt(short = "I", long = "ignore-socket-err", env = "WG_IGNORE_SOCKET_ERR")]
pub ignore_socket_errors: bool,
///Log all events to Stdout
#[structopt(short = "l", long = "log", env = "WG_LOG_EVENTS")]
pub log: bool,
///Socket for the userspace implementation to poll
#[structopt(name = "SOCKET", parse(from_os_str), env = "WG_EVENT_SOCKET")]
pub socket: PathBuf,
}