From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Peter Dyballa Newsgroups: gmane.emacs.help Subject: Re: Saving/Recalling Shell Commands History? Date: Mon, 21 Aug 2006 22:09:02 +0200 Message-ID: References: <1156172846.553787.214050@h48g2000cwc.googlegroups.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=UTF-8; delsp=yes; format=flowed Content-Transfer-Encoding: quoted-printable X-Trace: sea.gmane.org 1156190994 28746 80.91.229.2 (21 Aug 2006 20:09:54 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 21 Aug 2006 20:09:54 +0000 (UTC) Cc: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Aug 21 22:09:47 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1GFG5P-0003v2-TJ for geh-help-gnu-emacs@m.gmane.org; Mon, 21 Aug 2006 22:09:28 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GFG5P-0005Xq-Hb for geh-help-gnu-emacs@m.gmane.org; Mon, 21 Aug 2006 16:09:27 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1GFG5D-0005Vm-PW for help-gnu-emacs@gnu.org; Mon, 21 Aug 2006 16:09:15 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1GFG56-0005UG-Qk for help-gnu-emacs@gnu.org; Mon, 21 Aug 2006 16:09:15 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GFG56-0005UD-Ni for help-gnu-emacs@gnu.org; Mon, 21 Aug 2006 16:09:08 -0400 Original-Received: from [217.72.192.221] (helo=fmmailgate01.web.de) by monty-python.gnu.org with esmtp (Exim 4.52) id 1GFGCY-0007sy-Ix for help-gnu-emacs@gnu.org; Mon, 21 Aug 2006 16:16:50 -0400 Original-Received: from smtp07.web.de (fmsmtp07.dlan.cinetic.de [172.20.5.215]) by fmmailgate01.web.de (Postfix) with ESMTP id 052271519786; Mon, 21 Aug 2006 22:09:06 +0200 (CEST) Original-Received: from [87.193.11.125] (helo=[192.168.1.2]) by smtp07.web.de with asmtp (TLSv1:RC4-SHA:128) (WEB.DE 4.107 #114) id 1GFG52-00021Q-00; Mon, 21 Aug 2006 22:09:05 +0200 In-Reply-To: <1156172846.553787.214050@h48g2000cwc.googlegroups.com> X-Image-Url: http://homepage.mac.com/sparifankal/.cv/thumbs/me.thumbnail Original-To: gamename X-Mailer: Apple Mail (2.752.2) X-Sender: Peter_Dyballa@web.de X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:36809 Archived-At: Am 21.08.2006 um 17:07 schrieb gamename: > Hi, > > Is there any way to save the commands issued in shell-mode and recall > them when a new shell starts, or even in a new instance of emacs? > The documentation writes: (defun comint-read-input-ring (&optional silent) "Set the buffer's `comint-input-ring' from a history file. The name of the file is given by the variable = `comint-input-ring-=20 file-name'. The history ring is of size `comint-input-ring-size', regardless = of =20 file size. If `comint-input-ring-file-name' is nil this function does = nothing. =09 (defun comint-write-input-ring () "Writes the buffer's `comint-input-ring' to a history file. The name of the file is given by the variable = `comint-input-ring-=20 file-name'. The original contents of the file are lost if = `comint-input-ring' is =20 not empty. If `comint-input-ring-file-name' is nil this function does = nothing. Although I have set comint-input-ring-file-name, this file never gets =20= written. And neither read (I've put some uniq commands into it to see =20= if). All *shell* does in my case, is it reads ~/.tcsh_history =E2=80=93 =20= because I have tcsh as login shell. Could be there is bug, or I simply need to activate the described =20 behaviour with some start-up or shut-down hooks ... -- Greetings Pete =C2=BB=C2=BF=CA=87=C4=B1=CC=A3 =C9=99snq=C9=90 =CA=87,u=C9=90=C9=94 no=CA=8E= =C9=9F=C4=B1=CC=A3 =C9=93u=C4=B1=CC=A3=C9=A5=CA=87=CA=8Eu=C9=90 s=C4=B1=CC=A3 poo=C9=93 = =CA=87=C9=90=C9=A5=CA=8D=C2=AB