From: Karel Zak Date: Fri, 1 Oct 2021 12:47:04 +0000 (+0200) Subject: prlimit: improve --help output X-Git-Tag: v2.38-rc1~236 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3d6a3d6d2aa91a441a4c97133db78bce3989a6e3;p=thirdparty%2Futil-linux.git prlimit: improve --help output Signed-off-by: Karel Zak --- diff --git a/sys-utils/prlimit.c b/sys-utils/prlimit.c index eba73c751d..9317ba0442 100644 --- a/sys-utils/prlimit.c +++ b/sys-utils/prlimit.c @@ -159,14 +159,14 @@ static void __attribute__((__noreturn__)) usage(void) fputs(USAGE_HEADER, out); fprintf(out, - _(" %s [options] [-p PID]\n"), program_invocation_short_name); + _(" %s [options] [--=] [-p PID]\n"), program_invocation_short_name); fprintf(out, - _(" %s [options] COMMAND\n"), program_invocation_short_name); + _(" %s [options] [--=] COMMAND\n"), program_invocation_short_name); fputs(USAGE_SEPARATOR, out); fputs(_("Show or change the resource limits of a process.\n"), out); - fputs(_("\nGeneral Options:\n"), out); + fputs(USAGE_OPTIONS, out); fputs(_(" -p, --pid process id\n" " -o, --output define which output columns to use\n" " --noheadings don't print headings\n" @@ -175,7 +175,7 @@ static void __attribute__((__noreturn__)) usage(void) ), out); printf(USAGE_HELP_OPTIONS(24)); - fputs(_("\nResources Options:\n"), out); + fputs(_("\nResources:\n"), out); fputs(_(" -c, --core maximum size of core files created\n" " -d, --data maximum size of a process's data segment\n" " -e, --nice maximum nice priority allowed to raise\n" @@ -194,6 +194,11 @@ static void __attribute__((__noreturn__)) usage(void) " -y, --rttime CPU time in microseconds a process scheduled\n" " under real-time scheduling\n"), out); + fputs(USAGE_ARGUMENTS, out); + fputs(_( + " is defined as a range soft:hard, soft:, :hard or a value to\n" + " define both limits (e.g. -e=0:10 -r=:10).\n"), out); + fputs(USAGE_COLUMNS, out); for (i = 0; i < ARRAY_SIZE(infos); i++) fprintf(out, " %11s %s\n", infos[i].name, _(infos[i].help));