From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9065 invoked by alias); 29 Oct 2006 20:49:43 -0000 Received: (qmail 9038 invoked by uid 22791); 29 Oct 2006 20:49:41 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Sun, 29 Oct 2006 20:49:37 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1GeHb4-0002tO-Pd; Sun, 29 Oct 2006 15:49:34 -0500 Date: Sun, 29 Oct 2006 20:49:00 -0000 From: Daniel Jacobowitz To: Peng Yu Cc: gdb@sourceware.org Subject: Re: How to recall the commands run in previous gdb session? Message-ID: <20061029204933.GA11060@nevyn.them.org> Mail-Followup-To: Peng Yu , gdb@sourceware.org References: <366c6f340610291235u2d8a430el92c6c5353134c37e@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <366c6f340610291235u2d8a430el92c6c5353134c37e@mail.gmail.com> User-Agent: Mutt/1.5.13 (2006-08-11) X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-10/txt/msg00282.txt.bz2 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