cli: Added a welcome and help message

When gluster command is fired without any arguments it just shows the
prompt, so added a welcome message and info to get help.

fixes: bz#1535528

Change-Id: I627b66b67443716e9270025c1e47b98b6facba13
Signed-off-by: Rinku Kothiya <rkothiya@redhat.com>
This commit is contained in:
Rinku Kothiya 2019-01-14 13:24:20 +00:00 committed by Atin Mukherjee
parent c5bb929b36
commit 55b40dfbb2
2 changed files with 6 additions and 0 deletions

View File

@ -346,6 +346,9 @@ cli_rl_input(void *_data)
state = _data;
fprintf(stderr,
"Welcome to gluster prompt, type 'help' to see the available "
"commands.\n");
for (;;) {
line = readline(state->prompt);
if (!line)

View File

@ -45,6 +45,9 @@ cli_input(void *d)
state = d;
fprintf(stderr,
"Welcome to gluster prompt, type 'help' to see the available "
"commands.\n");
for (;;) {
printf("%s", state->prompt);