]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
unshare: remove -s from --help output
authorKarel Zak <kzak@redhat.com>
Tue, 11 Sep 2018 10:43:03 +0000 (12:43 +0200)
committerKarel Zak <kzak@redhat.com>
Tue, 11 Sep 2018 10:47:39 +0000 (12:47 +0200)
The code and man page do not assume -s to be short alias to
--setgroups.

This commit also a little bit change --help output formatting to make
it more readable and structured.

Addresses: https://github.com/karelzak/util-linux/pull/692
Signed-off-by: Karel Zak <kzak@redhat.com>
sys-utils/unshare.c

index 161cd27b96a0187c4109100a651e5f11de844c49..661665aeba250c10ea975e3e8a203b6337f8dde1 100644 (file)
@@ -259,13 +259,16 @@ static void __attribute__((__noreturn__)) usage(void)
        fputs(_(" -p, --pid[=<file>]        unshare pid namespace\n"), out);
        fputs(_(" -U, --user[=<file>]       unshare user namespace\n"), out);
        fputs(_(" -C, --cgroup[=<file>]     unshare cgroup namespace\n"), out);
+       fputs(USAGE_SEPARATOR, out);
        fputs(_(" -f, --fork                fork before launching <program>\n"), out);
-       fputs(_("     --kill-child[=<signame>]  when dying, kill the forked child (implies --fork); defaults to SIGKILL\n"), out);
-       fputs(_("     --mount-proc[=<dir>]  mount proc filesystem first (implies --mount)\n"), out);
        fputs(_(" -r, --map-root-user       map current user to root (implies --user)\n"), out);
-       fputs(_("     --propagation slave|shared|private|unchanged\n"
+       fputs(USAGE_SEPARATOR, out);
+       fputs(_(" --kill-child[=<signame>]  when dying, kill the forked child (implies --fork)\n"
+               "                             defaults to SIGKILL\n"), out);
+       fputs(_(" --mount-proc[=<dir>]      mount proc filesystem first (implies --mount)\n"), out);
+       fputs(_(" --propagation slave|shared|private|unchanged\n"
                "                           modify mount propagation in mount namespace\n"), out);
-       fputs(_(" -s, --setgroups allow|deny  control the setgroups syscall in user namespaces\n"), out);
+       fputs(_(" --setgroups allow|deny    control the setgroups syscall in user namespaces\n"), out);
 
        fputs(USAGE_SEPARATOR, out);
        printf(USAGE_HELP_OPTIONS(27));