This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: How to recall the commands run in previous gdb session?
- From: Daniel Jacobowitz <drow at false dot org>
- To: Peng Yu <pengyu dot ut at gmail dot com>
- Cc: gdb at sourceware dot org
- Date: Sun, 29 Oct 2006 15:49:34 -0500
- Subject: Re: How to recall the commands run in previous gdb session?
- References: <366c6f340610291235u2d8a430el92c6c5353134c37e@mail.gmail.com>
On Sun, Oct 29, 2006 at 02:35:38PM -0600, Peng Yu wrote:
> Hi,
>
> In the same gdb session, I can use up or down arrow to recall commands.
>
> But once a gdb session is start over, all the history commands are
> gone. I'm wondering if it is possible to recall those commands?
Take a look at the section on saving history in the GDB manual.
Someone else asked me about this last week. I've been thinking about
adjusting it to use ~/.gdb_history instead of ./.gdb_history by default
and then enabling it by default. After all, everyone seems to assume
their shell will save CLI history, why shouldn't we?
--
Daniel Jacobowitz
CodeSourcery