]> git.ipfire.org Git - thirdparty/libcgroup.git/commitdiff
unify libcgroup tools -h output
authorIvana Hutarova Varekova <varekova@redhat.com>
Wed, 18 Jul 2012 18:53:09 +0000 (20:53 +0200)
committerIvana Hutarova Varekova <varekova@redhat.com>
Wed, 18 Jul 2012 18:53:09 +0000 (20:53 +0200)
unify libcgroup tools -h output

use <controllers>:<path> as a parameter of -g
        * cgclassify
        * cgget

fix typos
        * cgget
        * cgset

fix indentation
        * cgconfig
        * cgsnapshot

Signed-off-by: Ivana Hutarova Varekova <varekova@redhat.com>
Acked-by: Jan Safranek <jsafrane@redhat.com>
Acked-by: Dhaval Giani <dhaval.giani@gmail.com>
src/tools/cgclassify.c
src/tools/cgconfig.c
src/tools/cgcreate.c
src/tools/cgget.c
src/tools/cgset.c
src/tools/cgsnapshot.c

index 397b7252b8e0278b77eeeb99193972dc30c5844a..3f19a4dce9feaa6b90e31378a0bab2168552b4ed 100644 (file)
@@ -38,9 +38,9 @@ static void usage(int status, const char *program_name)
                        " try %s -h' for more information.\n",
                        program_name);
        } else {
-               printf("usage is %s "
-                       "[-g <list of controllers>:<relative path to cgroup>] "
-                       "[--sticky | --cancel-sticky] <list of pids>  \n",
+               printf("usage is %s"\
+                       "[-g <controllers>:<path>]"
+                       "[--sticky | --cancel-sticky] <list of pids>\n",
                        program_name);
        }
 }
index bf9bfa8d0a94d151faec6b891c487664451a688a..da4486bcf8225e1a9e2cf78e8a8f624710338a08 100644 (file)
@@ -39,7 +39,7 @@ static void usage(char *progname)
 {
        printf("Usage: %s [-h] [-f mode] [-d mode] [-s mode] "\
                        "[-t <tuid>:<tgid>] [-a <agid>:<auid>] "\
-                       "[-l FILE] [-L directory] ...\n", basename(progname));
+                       "[-l FILE] [-L DIR] ...\n", basename(progname));
        printf("Parse and load the specified cgroups configuration file\n");
        printf("\n");
        printf("  -h, --help                    Display this help\n");
@@ -53,7 +53,7 @@ static void usage(char *progname)
                        " permissions\n");
        printf("  -f, --fperm=mode              Default group file"\
                        " permissions\n");
-       printf("  -s --tperm=mode               Default tasks file"
+       printf("  -s, --tperm=mode              Default tasks file"
                        " permissions\n");
        printf("  -t <tuid>:<tgid>              Default owner of the tasks "
                        "file\n");
index d10bd454cf9c9dd3b34e7b97d04a607fc5c67c44..b0003b1eb47a9c94612b8cd00398179f7f8179f8 100644 (file)
@@ -42,6 +42,7 @@ static void usage(int status, const char *program_name)
                        "[-s mode] [-t <tuid>:<tgid>] [-a <agid>:<auid>] "\
                        "-g <controllers>:<path> [-g ...]\n",
                        program_name);
+               fprintf(stdout, "Create control group(s)\n");
                fprintf(stdout, "  -a <tuid>:<tgid>             Owner "\
                        "of the group and all its files\n");
                fprintf(stdout, "  -d, --dperm=mode             Group "\
index ea638b4ccdedc4f59800edc66cdbaebe3f2b1fb7..49a447c6cb0477c2b30e493fe539ed71a30b1a47 100644 (file)
@@ -39,16 +39,16 @@ static void usage(int status, const char *program_name)
                        program_name);
        else {
                fprintf(stdout, "Usage: %s [-nv] [-r <name>] "\
-                       "[-g <controller>] [-a] <path> ...\n", program_name);
+                       "[-g <controllers>] [-a] <path> ...\n", program_name);
                fprintf(stdout, "   or: %s [-nv] [-r <name>] "\
-                       "-g <controller>:<path> ...\n", program_name);
+                       "-g <controllers>:<path> ...\n", program_name);
                fprintf(stdout, "Print parameter(s) of given group(s).\n");
                fprintf(stdout, "  -a, --all                    "\
                        "Print info about all relevant controllers\n");
-               fprintf(stdout, "  -g <controller             "\
-                       "Controller which info should be displaied\n");
-               fprintf(stdout, "  -g <controller>:<path>       "\
-                       "Control group whih info should be displaied\n");
+               fprintf(stdout, "  -g <controllers>             "\
+                       "Controller which info should be displayed\n");
+               fprintf(stdout, "  -g <controllers>:<path>      "\
+                       "Control group which info should be displayed\n");
                fprintf(stdout, "  -h, --help                   "\
                        "Display this help\n");
                fprintf(stdout, "  -n                           "\
@@ -407,7 +407,7 @@ int main(int argc, char *argv[])
 
        if (((group_needed == 2) && (argv[optind])) ||
            ((group_needed != 2) && (!argv[optind]))) {
-               /* mixed -g <controller>:<path> and <path> or path not set */
+               /* mixed -g <controllers>:<path> and <path> or path not set */
                usage(1, argv[0]);
                result = -1;
                goto err;
index c631e0fe714ede7ae636d487df017d4bed6bc5b4..8f1af524a16dd4be54f69f731566caa3c1576b65 100644 (file)
@@ -63,7 +63,7 @@ static void usage(int status, const char *program_name)
                        program_name);
        else {
                printf("Usage: %s [-r <name=value>]  <cgroup_path> ...\n"
-                       "   or: %s --copy-from <source_cgrup_path> "
+                       "   or: %s --copy-from <source_cgroup_path> "
                            "<cgroup_path> ...\n",
                        program_name, program_name);
        }
index c14542987ba637938349ed94e0f5af11e94f1079..324f93b5a9c8c2640d8fca842e5687893815bece 100644 (file)
@@ -60,21 +60,21 @@ static void usage(int status, const char *program_name)
                        " try %s -h' for more information.\n",
                        program_name);
        } else {
-               fprintf(stdout, "Usage: %s [-h] [-s] [-b file] "\
-                       "[-w file] [-f output_file] "\
+               fprintf(stdout, "Usage: %s [-h] [-s] [-b FILE] "\
+                       "[-w FILE] [-f FILE] "\
                        "[controller] [...]\n", program_name);
                fprintf(stdout, "Generate the configuration file from "\
                        "the given controllers of control groups\n");
-               fprintf(stdout, "  -b,--blacklist file  Set the blacklist"\
+               fprintf(stdout, "  -b, --blacklist=FILE  Set the blacklist"\
                        " configuration file (default %s)\n", BLACKLIST_CONF);
-               fprintf(stdout, "  -f,--file            Redirect the output"\
+               fprintf(stdout, "  -f, --file=FILE       Redirect the output"\
                        " to output_file\n");
-               fprintf(stdout, "  -h,--help            Display this help\n");
-               fprintf(stdout, "  -s,--silent          Ignore all "\
+               fprintf(stdout, "  -h, --help            Display this help\n");
+               fprintf(stdout, "  -s, --silent          Ignore all "\
                        "warnings\n");
-               fprintf(stdout, "  -t,--strict          Don't show the "\
+               fprintf(stdout, "  -t, --strict          Don't show the "\
                        "variables which are not on the whitelist\n");
-               fprintf(stdout, "  -w,--whitelist file  Set the whitelist"\
+               fprintf(stdout, "  -w, --whitelist=FILE  Set the whitelist"\
                        " configuration file (don't used by default)\n");
        }
 }