improve documentation

This commit is contained in:
Jan Christian Gr??nhage 2020-04-06 22:50:32 +02:00
parent b5e72dacb0
commit a1f772efe2
Signed by: jcgruenhage
GPG key ID: 6594C449C633D10C
4 changed files with 13 additions and 2 deletions

View file

@ -5,6 +5,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [Unreleased] ## [Unreleased]
### Added
- added documentation to the sample config file
- improved help message
## [v0.2.1] - 2020-04-06 ## [v0.2.1] - 2020-04-06
### Fixed ### Fixed

View file

@ -19,7 +19,8 @@ USAGE:
FLAGS: FLAGS:
-h, --help Prints help information -h, --help Prints help information
-v, --verbose Be verbose (you can add this up to 4 times for more logs) -v, --verbose Be verbose (you can add this up to 4 times for more logs).
By default, only errors are logged, so no output is a good thing.
-V, --version Prints version information -V, --version Prints version information
ARGS: ARGS:

View file

@ -1,5 +1,11 @@
# Defines where the metrics will be served.
# Takes the format IPv4:port or [IPv6]:port
listener = "[::]:9898" listener = "[::]:9898"
# Array of hosts to ping. Currently only supports plain IPs, no DNS names.
# The format here is `"host" = interval in milliseconds`, so these examples
# will ping the primary and secondary IP of cloudflare's 1.1.1.1 DNS service
# every 500ms, or twice per second.
[hosts] [hosts]
"1.1.1.1" = 500 "1.1.1.1" = 500
"1.0.0.1" = 500 "1.0.0.1" = 500

View file

@ -35,7 +35,8 @@ pub(crate) fn setup_clap() -> clap::ArgMatches<'static> {
(author: crate_authors!()) (author: crate_authors!())
(about: crate_description!()) (about: crate_description!())
(@arg config: +required "Set config file") (@arg config: +required "Set config file")
(@arg v: -v --verbose ... "Be verbose (you can add this up to 4 times for more logs)") (@arg v: -v --verbose ... "Be verbose (you can add this up to 4 times for more logs).
By default, only errors are logged, so no output is a good thing.")
) )
.get_matches() .get_matches()
} }