xbps-fbulk: add -h for usage().
This commit is contained in:
parent
3d70668ad6
commit
6df2ff69fe
@ -151,7 +151,7 @@ addItem(const char *pkgn)
|
|||||||
static void __attribute__((noreturn))
|
static void __attribute__((noreturn))
|
||||||
usage(const char *progname)
|
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);
|
"/path/to/void-packages [pkg pkgN]\n", progname);
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
@ -548,7 +548,7 @@ main(int argc, char **argv)
|
|||||||
size_t blen;
|
size_t blen;
|
||||||
int ch;
|
int ch;
|
||||||
|
|
||||||
while ((ch = getopt(argc, argv, "a:j:l:v")) != -1) {
|
while ((ch = getopt(argc, argv, "a:hj:l:v")) != -1) {
|
||||||
switch (ch) {
|
switch (ch) {
|
||||||
case 'a':
|
case 'a':
|
||||||
TargetArch = optarg;
|
TargetArch = optarg;
|
||||||
@ -562,6 +562,7 @@ main(int argc, char **argv)
|
|||||||
case 'l':
|
case 'l':
|
||||||
LogDir = optarg;
|
LogDir = optarg;
|
||||||
break;
|
break;
|
||||||
|
case 'h':
|
||||||
default:
|
default:
|
||||||
usage(progname);
|
usage(progname);
|
||||||
/* NOT REACHED */
|
/* NOT REACHED */
|
||||||
|
Loading…
Reference in New Issue
Block a user