Skip to content

Commit c185101

Browse files
authored
CA-413424: Enhance xe help output (#6584)
The previous `xe` help is as below: ``` Usage: xe <cmd> [-s server] [-p port] ([-u username] [-pw password] or [-pwf <password file>]) [--traceparent traceparent] <other arguments> A full list of commands can be obtained by running xe help -s <server> -p <port> ``` The previous `xe` help output lacked debug-related options and did not provide detailed parameter description. The new `xe` help output is as follows: ``` Usage: xe <command> [ -s <server> ] XenServer host [ -p <port> ] XenServer port number [ -u <username> -pw <password> | -pwf <password file> ] User authentication (password or file) [ --nossl ] Disable SSL/TLS [ --debug ] Enable debug output [ --debug-on-fail ] Enable debug output only on failure [ --traceparent <value> ] Distributed tracing context [ <other arguments> ... ] Command-specific options A full list of commands can be obtained by running xe help -s <server> -p <port> ```
2 parents f6238a0 + 97e50cf commit c185101

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

ocaml/xe-cli/newcli.ml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,13 +67,22 @@ exception Usage
6767

6868
let usage () =
6969
error
70-
"Usage: %s <cmd> [-s server] [-p port] ([-u username] [-pw password] or \
71-
[-pwf <password file>]) [--traceparent traceparent] <other arguments>\n"
70+
"Usage:\n\
71+
\ %s <command>\n\
72+
\ [ -s <server> ] XenServer host \n\
73+
\ [ -p <port> ] XenServer port number \n\
74+
\ [ -u <username> -pw <password> | -pwf <password file> ] \n\
75+
\ User authentication (password or file) \n\
76+
\ [ --nossl ] Disable SSL/TLS \n\
77+
\ [ --debug ] Enable debug output \n\
78+
\ [ --debug-on-fail ] Enable debug output only on failure \n\
79+
\ [ --traceparent <value> ] Distributed tracing context \n\
80+
\ [ <other arguments> ... ] Command-specific options \n"
7281
Sys.argv.(0) ;
7382
error
7483
"\n\
7584
A full list of commands can be obtained by running \n\
76-
\t%s help -s <server> -p <port>\n"
85+
\ %s help -s <server> -p <port>\n"
7786
Sys.argv.(0)
7887

7988
let is_localhost ip = ip = "127.0.0.1"

0 commit comments

Comments
 (0)