Re: [Qemu-devel] [PATCH] qemu-img.c: add help for each command

2018-09-10 Thread Programmingkid
> On Sep 10, 2018, at 4:16 AM, Kevin Wolf wrote: > > Am 08.09.2018 um 05:16 hat Programmingkid geschrieben: >> >>> On Sep 7, 2018, at 11:13 PM, Peter Maydell wrote: >>> >>> On 8 September 2018 at 04:01, John Arbuckle >>> wrote: >>> +/* print the help for this command */ +

Re: [Qemu-devel] [PATCH] qemu-img.c: add help for each command

2018-09-10 Thread Kevin Wolf
Am 08.09.2018 um 05:16 hat Programmingkid geschrieben: > > > On Sep 7, 2018, at 11:13 PM, Peter Maydell wrote: > > > > On 8 September 2018 at 04:01, John Arbuckle > > wrote: > > > >> +/* print the help for this command */ > >> +if (strcmp("--help", argv[optind + 1]) == 0) { > >> +

Re: [Qemu-devel] [PATCH] qemu-img.c: add help for each command

2018-09-07 Thread Programmingkid
> On Sep 7, 2018, at 11:13 PM, Peter Maydell wrote: > > On 8 September 2018 at 04:01, John Arbuckle wrote: > >> +/* print the help for this command */ >> +if (strcmp("--help", argv[optind + 1]) == 0) { >> +if (strcmp("amend", cmdname) == 0) { >> +help_amend(); >>

Re: [Qemu-devel] [PATCH] qemu-img.c: add help for each command

2018-09-07 Thread Peter Maydell
On 8 September 2018 at 04:01, John Arbuckle wrote: > +/* print the help for this command */ > +if (strcmp("--help", argv[optind + 1]) == 0) { > +if (strcmp("amend", cmdname) == 0) { > +help_amend(); > +} else if (strcmp("bench", cmdname) == 0) { > +

[Qemu-devel] [PATCH] qemu-img.c: add help for each command

2018-09-07 Thread John Arbuckle
Add the ability for the user to display help for a certain command. Example: qemu-img create --help What is printed is all the options available to this command and an example. Signed-off-by: John Arbuckle --- qemu-img.c | 767 + 1