Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <pedro@codesourcery.com>
To: gdb-patches@sourceware.org
Cc: Chris Moller <cmoller@redhat.com>,  Phil Muldoon <pmuldoon@redhat.com>
Subject: Re: A patch I'd like to propose.
Date: Wed, 14 Apr 2010 17:20:00 -0000	[thread overview]
Message-ID: <201004141819.48480.pedro@codesourcery.com> (raw)
In-Reply-To: <4BC5D144.2080105@redhat.com>

On Wednesday 14 April 2010 15:29:24, Chris Moller wrote:
> On 04/14/10 10:19, Phil Muldoon wrote:
> > On 04/14/2010 12:59 PM, Chris Moller wrote:
> >    
> >> Adds the command "quickquit," aliased to "qq," to cli/cli-cmds.c.   It
> >> eliminates that annoying quit_confirm() when quitting gdb.
> >>      
> >
> > 'set confirm off' works for me?  Though this is not the default it
> > seems.  Is this orthogonal to your request, or did you want an
> > explicit command to act regardless of confirm off/on?
> >    
> 
> I'm looking for something that always works without me having to make 
> any special arrangement for it.  I use a lot of bizarre environments in 
> debugging and a lot of the time I've forgotten things like copying over 
> my usual~/.gdbinit

That's what you should be fixing then, isn't it?  ;-)

 define qq
   set confirm off
   quit
 end

Kinda misses the scripting point we add commands for everything
that's _already_ easily possible, even with CLI scripting.

In any case, I'd be okay with this with the following constrains:

* It was rather called "quit-force", or something similarly, so that:

 - q<tab> does't stop completing to "quit", but instead even
   proposes "quit"/"quit-force" to the user.  As bonus, users notice
   the new command is available.

 - the fact that `qq' is typo-prone is avoided.  E.g., "quit-force" -> qf.

* q, qu, qui, remain unambiguous aliases to "quit".  "quickquit" shares
3 initials with "quit", so q will stop working if aliases are not added.

* You explain whether you mean for this to disable _all_ queries
when quitting or not.  I think that's what you meant.  As is, it
doesn't do that, because e.g.,

 +void
 +quick_quit_command (char *args, int from_tty)
 +{
 +  disconnect_tracing (from_tty);
    ^^^^^^^^^^^^^^^^^^

This can query.

 +
 +  quit_force (args, from_tty);
 +}

* Of course, that this is documented in the manual.

-- 
Pedro Alves


  reply	other threads:[~2010-04-14 17:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-14 11:59 Chris Moller
2010-04-14 14:19 ` Phil Muldoon
2010-04-14 14:29   ` Chris Moller
2010-04-14 17:20     ` Pedro Alves [this message]
2010-04-14 17:05 ` Joel Brobecker
2010-04-14 17:20   ` Michael Snyder

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=201004141819.48480.pedro@codesourcery.com \
    --to=pedro@codesourcery.com \
    --cc=cmoller@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=pmuldoon@redhat.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