Re: [Qemu-devel] [PATCH for-2.11 v2 4/5] qmp-shell: Accept QMP command as argument

2017-08-21 Thread Markus Armbruster
Eduardo Habkost writes: > On Wed, Aug 16, 2017 at 08:25:41AM +0200, Markus Armbruster wrote: >> Eduardo Habkost writes: >> >> > On Tue, Aug 15, 2017 at 12:03:53PM +0200, Markus Armbruster wrote: >> >> Eduardo Habkost writes: >> >> >> >> Suggest to insert here: >> >> >> >> If additional arg

Re: [Qemu-devel] [PATCH for-2.11 v2 4/5] qmp-shell: Accept QMP command as argument

2017-08-18 Thread Eduardo Habkost
On Wed, Aug 16, 2017 at 08:25:41AM +0200, Markus Armbruster wrote: > Eduardo Habkost writes: > > > On Tue, Aug 15, 2017 at 12:03:53PM +0200, Markus Armbruster wrote: > >> Eduardo Habkost writes: > >> > >> Suggest to insert here: > >> > >> If additional arguments QMP-COMMAND ARG=VAL... are gi

Re: [Qemu-devel] [PATCH for-2.11 v2 4/5] qmp-shell: Accept QMP command as argument

2017-08-15 Thread Markus Armbruster
Eduardo Habkost writes: > On Tue, Aug 15, 2017 at 12:03:53PM +0200, Markus Armbruster wrote: >> Eduardo Habkost writes: >> >> Suggest to insert here: >> >> If additional arguments QMP-COMMAND ARG=VAL... are given, run just >> that QMP command instead of the REPL. >> >> Question: is this l

Re: [Qemu-devel] [PATCH for-2.11 v2 4/5] qmp-shell: Accept QMP command as argument

2017-08-15 Thread Eduardo Habkost
On Tue, Aug 15, 2017 at 12:03:53PM +0200, Markus Armbruster wrote: > Eduardo Habkost writes: > > Suggest to insert here: > > If additional arguments QMP-COMMAND ARG=VAL... are given, run just > that QMP command instead of the REPL. > > Question: is this limited to simple arguments? If no,

Re: [Qemu-devel] [PATCH for-2.11 v2 4/5] qmp-shell: Accept QMP command as argument

2017-08-15 Thread Markus Armbruster
Eduardo Habkost writes: Suggest to insert here: If additional arguments QMP-COMMAND ARG=VAL... are given, run just that QMP command instead of the REPL. Question: is this limited to simple arguments? If no, how would I write an object argument? For instance, how would I do { "execute

Re: [Qemu-devel] [PATCH for-2.11 v2 4/5] qmp-shell: Accept QMP command as argument

2017-08-09 Thread Stefan Hajnoczi
On Tue, Aug 08, 2017 at 05:39:34PM -0300, Eduardo Habkost wrote: > This is useful for testing QMP commands in scripts. > > Example usage, combined with 'jq' for filtering the results: > > $ ./scripts/qmp/qmp-shell /tmp/qmp qom-list path=/ | jq -r .return[].name > machine > type > chardevs

[Qemu-devel] [PATCH for-2.11 v2 4/5] qmp-shell: Accept QMP command as argument

2017-08-08 Thread Eduardo Habkost
This is useful for testing QMP commands in scripts. Example usage, combined with 'jq' for filtering the results: $ ./scripts/qmp/qmp-shell /tmp/qmp qom-list path=/ | jq -r .return[].name machine type chardevs backend $ Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Rewritten