From 7c48546ad38be961940a13a6021d8c61a47c594f Mon Sep 17 00:00:00 2001 From: Gabor Javorszky Date: Mon, 16 Sep 2024 11:30:08 +0100 Subject: tools/unitctl: adjust readme for socket addresses CONTROL_SOCKET_ADDRESS is singular, adds note that the flag can be specified multiple times, and adjusts code to print CONTROL_SOCKET_ADDRESS as singular. Signed-off-by: Gabor Javorszky Signed-off-by: Andrew Clayton --- tools/unitctl/README.md | 2 +- tools/unitctl/unitctl/src/unitctl.rs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/tools/unitctl/README.md b/tools/unitctl/README.md index 953956a3..1a5fcb9d 100644 --- a/tools/unitctl/README.md +++ b/tools/unitctl/README.md @@ -69,7 +69,7 @@ Commands: Options: -s, --control-socket-address - Path (unix:/var/run/unit/control.sock), tcp address with port (127.0.0.1:80), or URL + Path (unix:/var/run/unit/control.sock), tcp address with port (127.0.0.1:80), or URL. This flag can be specified multiple times. -w, --wait-timeout-seconds Number of seconds to wait for control socket to become available -t, --wait-max-tries diff --git a/tools/unitctl/unitctl/src/unitctl.rs b/tools/unitctl/unitctl/src/unitctl.rs index a4c13648..460c7e7b 100644 --- a/tools/unitctl/unitctl/src/unitctl.rs +++ b/tools/unitctl/unitctl/src/unitctl.rs @@ -14,7 +14,8 @@ pub(crate) struct UnitCtl { short = 's', long = "control-socket-address", value_parser = parse_control_socket_address, - help = "Path (unix:/var/run/unit/control.sock), tcp address with port (127.0.0.1:80), or URL" + value_name = "CONTROL_SOCKET_ADDRESS", + help = "Path (unix:/var/run/unit/control.sock), tcp address with port (127.0.0.1:80), or URL. This flag can be specified multiple times." )] pub(crate) control_socket_addresses: Option>, -- cgit