On 07/17/2012 04:26 PM, Ivana Hutarova Varekova wrote: > 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 <varek...@redhat.com>
Acked-By: Jan Safranek <jsafr...@redhat.com> > --- > > src/tools/cgclassify.c | 6 +++--- > src/tools/cgconfig.c | 4 ++-- > src/tools/cgcreate.c | 1 + > src/tools/cgget.c | 14 +++++++------- > src/tools/cgset.c | 2 +- > src/tools/cgsnapshot.c | 16 ++++++++-------- > 6 files changed, 22 insertions(+), 21 deletions(-) > > diff --git a/src/tools/cgclassify.c b/src/tools/cgclassify.c > index 397b725..3f19a4d 100644 > --- a/src/tools/cgclassify.c > +++ b/src/tools/cgclassify.c > @@ -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); > } > } > diff --git a/src/tools/cgconfig.c b/src/tools/cgconfig.c > index bf9bfa8..da4486b 100644 > --- a/src/tools/cgconfig.c > +++ b/src/tools/cgconfig.c > @@ -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"); > diff --git a/src/tools/cgcreate.c b/src/tools/cgcreate.c > index d10bd45..b0003b1 100644 > --- a/src/tools/cgcreate.c > +++ b/src/tools/cgcreate.c > @@ -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 "\ > diff --git a/src/tools/cgget.c b/src/tools/cgget.c > index ea638b4..49a447c 100644 > --- a/src/tools/cgget.c > +++ b/src/tools/cgget.c > @@ -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; > diff --git a/src/tools/cgset.c b/src/tools/cgset.c > index c631e0f..8f1af52 100644 > --- a/src/tools/cgset.c > +++ b/src/tools/cgset.c > @@ -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); > } > diff --git a/src/tools/cgsnapshot.c b/src/tools/cgsnapshot.c > index c145429..324f93b 100644 > --- a/src/tools/cgsnapshot.c > +++ b/src/tools/cgsnapshot.c > @@ -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"); > } > } > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Libcg-devel mailing list > Libcg-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/libcg-devel > ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Libcg-devel mailing list Libcg-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libcg-devel