From: Philippe Waroquiers <philippe.waroquiers@skynet.be>
To: Tom Tromey <tom@tromey.com>, Gary Benson <gbenson@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH] Indicate batch mode failures by exiting with nonzero status
Date: Sat, 25 Aug 2018 19:52:00 -0000 [thread overview]
Message-ID: <1535226739.1438.8.camel@skynet.be> (raw)
In-Reply-To: <87bm9ygyiv.fsf@tromey.com>
On Sun, 2018-08-19 at 09:35 -0600, Tom Tromey wrote:
> > > > > > "Gary" == Gary Benson <gbenson@redhat.com> writes:
> > > Also, why just the last command? I mean, I guess I don't really know
> > > what I would expect, but maybe if any command failed, gdb should exit?
>
> Gary> That was my thinking, to have GDB exit 1 on the first error in batch
> Gary> mode, but people objected; see the followups to:
>
> Oh, ok, sorry for wading into an already open issue without the
> background.
>
> On reflection perhaps I'm overthinking it. It seems to me that it is
> fine for these command line options to be defined based on whatever
> seems convenient.
>
> For "real" scripting, a script file could be used. Maybe we could
> finally land that try/catch patch, or the ignore-errors command.
> Or, longer term, finally make it possible to really script with Python.
Note that I still have on my list of things to do to rework
the 'block of commands' patch that I started some (long) time ago.
One of the objectives was to allow to group commands in blocks such as:
{ command1 ; command2 ; command3 }
And have (optional) flags -c and -s to follow the {
to control continuing (silently or not) the execution
of a sequence of commands when there is a failure.
Another objective is to allow something like:
 thread apply all { command1; command 2}
and similar for frame apply,
Philippe
prev parent reply other threads:[~2018-08-25 19:52 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-16 13:23 Gary Benson
2018-08-16 23:46 ` Tom Tromey
2018-08-17 10:59 ` Gary Benson
2018-08-17 14:28 ` Pedro Alves
2018-08-17 15:38 ` Gary Benson
2018-08-19 15:35 ` Tom Tromey
2018-08-25 19:52 ` Philippe Waroquiers [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1535226739.1438.8.camel@skynet.be \
--to=philippe.waroquiers@skynet.be \
--cc=gbenson@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=tom@tromey.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox