xenomai.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: liyinjie <liyinjie@sinsegye.com.cn>
To: xenomai@lists.linux.dev
Cc: liyinjie <liyinjie@sinsegye.com.cn>
Subject: [PATCH] commands/evl: improve argument of help
Date: Sat,  7 Oct 2023 19:19:15 +0800	[thread overview]
Message-ID: <20231007111914.1351049-1-liyinjie@sinsegye.com.cn> (raw)

Enter the command `evl --help`, output

usage: evl [options] [<command> [<args>]]
-P --prefix=<path>   set command path prefix
-v -V --version      print library and required ABI versions
-h --help            this help
evl: no 'help' command. Try 'evl --help'.

This patch will fix incorrect output "evl: no 'help' command. Try 'evl --help'.".

Signed-off-by: liyinjie <liyinjie@sinsegye.com.cn>
---
 utils/evl.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/utils/evl.c b/utils/evl.c
index 0254cad..79cf5ec 100644
--- a/utils/evl.c
+++ b/utils/evl.c
@@ -96,7 +96,9 @@ int main(int argc, char *const argv[])
 			exit(0);
 		case 'h':
 			cmd = "help";
-			break;
+			usage();
+
+			exit(0);
 		case '?':
 			usage();
 			return 2;
-- 
2.25.1


             reply	other threads:[~2023-10-07 11:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-07 11:19 liyinjie [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-10-07 11:23 [PATCH] commands/evl: improve argument of help liyinjie
2023-10-07 14:03 ` Philippe Gerum

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231007111914.1351049-1-liyinjie@sinsegye.com.cn \
    --to=liyinjie@sinsegye.com.cn \
    --cc=xenomai@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).