public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug gdb/16136] New: Make users aware of the ./.gdb_history -> ~/.gdb_history default command history file change.
@ 2013-11-07 10:58 palves at redhat dot com
  2013-11-07 11:02 ` [Bug gdb/16136] " palves at redhat dot com
  2013-11-07 11:47 ` palves at redhat dot com
  0 siblings, 2 replies; 3+ messages in thread
From: palves at redhat dot com @ 2013-11-07 10:58 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=16136

            Bug ID: 16136
           Summary: Make users aware of the ./.gdb_history ->
                    ~/.gdb_history default command history file change.
           Product: gdb
           Version: HEAD
            Status: NEW
          Severity: normal
          Priority: P2
         Component: gdb
          Assignee: unassigned at sourceware dot org
          Reporter: palves at redhat dot com

GDB always reads the command history file, even if history save is
off.  Currently, the default history filename is ./.gdb_history.  This
has been a long time default.  If we switch the default to
~/.gdb_history, there'll be lots of users with lots of ./.gdb_history
files that will now silently no longer be read in.

So, there are two possible fronts that could be considered here:

 - backwards compatibility
 - user awareness of the change

One idea to maintain backwards compatibility would be to check if
./.gdb_history, if it exists.  If the history filename set actually
points elsewhere, GDB would tell the user that history is saved in
wherever the user has set it to (~/.gdb_history by default), and ask
her whether to read/save there or to .gdb_history.  A variant of this
would be to always read from ./.gdb_history if it exists, and ask
whether to save there, or to the user's configured location
(~/.gdb_history by default).

Or, we could tackle only the awareness part.  We could make gdb check
if a ./.gdbinit file exists and warn if the history filename actually
points elsewhere, with a hint on how to load that history file, but
not actually load it.  We have precedent for something like that in
windows-nat.c:_initialize_check_for_gdb_ini.

IMO, the former is more complexity (and possible confusion) than
necessary.  I think I prefer the simpler idea of tackling only
awareness.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug gdb/16136] Make users aware of the ./.gdb_history -> ~/.gdb_history default command history file change.
  2013-11-07 10:58 [Bug gdb/16136] New: Make users aware of the ./.gdb_history -> ~/.gdb_history default command history file change palves at redhat dot com
@ 2013-11-07 11:02 ` palves at redhat dot com
  2013-11-07 11:47 ` palves at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: palves at redhat dot com @ 2013-11-07 11:02 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=16136

Pedro Alves <palves at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Blocks|                            |15224

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug gdb/16136] Make users aware of the ./.gdb_history -> ~/.gdb_history default command history file change.
  2013-11-07 10:58 [Bug gdb/16136] New: Make users aware of the ./.gdb_history -> ~/.gdb_history default command history file change palves at redhat dot com
  2013-11-07 11:02 ` [Bug gdb/16136] " palves at redhat dot com
@ 2013-11-07 11:47 ` palves at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: palves at redhat dot com @ 2013-11-07 11:47 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=16136

--- Comment #1 from Pedro Alves <palves at redhat dot com> ---
To clarify, this:

> One idea to maintain backwards compatibility would be to check if
> ./.gdb_history, if it exists.  If the history filename set actually

should have read:

 One idea to maintain backwards compatibility would be to check if
 ./.gdb_history exists.  If so, and if the history filename set actually
 ...

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-11-07 11:47 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-11-07 10:58 [Bug gdb/16136] New: Make users aware of the ./.gdb_history -> ~/.gdb_history default command history file change palves at redhat dot com
2013-11-07 11:02 ` [Bug gdb/16136] " palves at redhat dot com
2013-11-07 11:47 ` palves at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).