From 6df2ff69fe195b1102d272248d514b4d16309aa8 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Thu, 4 Jun 2015 10:02:16 +0200 Subject: [PATCH] xbps-fbulk: add -h for usage(). --- bin/xbps-fbulk/main.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bin/xbps-fbulk/main.c b/bin/xbps-fbulk/main.c index 96ec072f..44d58a2f 100644 --- a/bin/xbps-fbulk/main.c +++ b/bin/xbps-fbulk/main.c @@ -151,7 +151,7 @@ addItem(const char *pkgn) static void __attribute__((noreturn)) usage(const char *progname) { - fprintf(stderr, "%s [-a targetarch] [-j parallel] [-l logdir] " + fprintf(stderr, "%s [-a targetarch] [-h] [-j parallel] [-l logdir] " "/path/to/void-packages [pkg pkgN]\n", progname); exit(EXIT_FAILURE); } @@ -548,7 +548,7 @@ main(int argc, char **argv) size_t blen; int ch; - while ((ch = getopt(argc, argv, "a:j:l:v")) != -1) { + while ((ch = getopt(argc, argv, "a:hj:l:v")) != -1) { switch (ch) { case 'a': TargetArch = optarg; @@ -562,6 +562,7 @@ main(int argc, char **argv) case 'l': LogDir = optarg; break; + case 'h': default: usage(progname); /* NOT REACHED */