From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#5148: Lossage in comint history Date: Mon, 07 Dec 2009 14:23:46 -0500 Message-ID: References: <87iqcjeq45.fsf@mail.jurta.org> Reply-To: Stefan Monnier , 5148@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1260217069 18394 80.91.229.12 (7 Dec 2009 20:17:49 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 7 Dec 2009 20:17:49 +0000 (UTC) Cc: 5148@emacsbugs.donarmstrong.com To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Dec 07 21:17:42 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1NHk1c-0003De-L0 for geb-bug-gnu-emacs@m.gmane.org; Mon, 07 Dec 2009 21:17:41 +0100 Original-Received: from localhost ([127.0.0.1]:60441 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NHk1c-0007Sc-Ao for geb-bug-gnu-emacs@m.gmane.org; Mon, 07 Dec 2009 15:17:40 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NHjYb-0001RV-AQ for bug-gnu-emacs@gnu.org; Mon, 07 Dec 2009 14:47:41 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NHjYV-0001IJ-6P for bug-gnu-emacs@gnu.org; Mon, 07 Dec 2009 14:47:39 -0500 Original-Received: from [199.232.76.173] (port=52354 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NHjYU-0001Hv-TU for bug-gnu-emacs@gnu.org; Mon, 07 Dec 2009 14:47:34 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:58512) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NHjYU-0003yS-Ct for bug-gnu-emacs@gnu.org; Mon, 07 Dec 2009 14:47:34 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nB7JlUKq003606; Mon, 7 Dec 2009 11:47:31 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.14.3/8.14.3/Submit) id nB7JUAOr002059; Mon, 7 Dec 2009 11:30:10 -0800 Resent-Date: Mon, 7 Dec 2009 11:30:10 -0800 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Stefan Monnier Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Mon, 07 Dec 2009 19:30:10 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 5148 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 5148-submit@emacsbugs.donarmstrong.com id=B5148.12602138311452 (code B ref 5148); Mon, 07 Dec 2009 19:30:10 +0000 Original-Received: (at 5148) by emacsbugs.donarmstrong.com; 7 Dec 2009 19:23:51 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from chene.dit.umontreal.ca (chene.dit.umontreal.ca [132.204.246.20]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nB7JNmYO001446 for <5148@emacsbugs.donarmstrong.com>; Mon, 7 Dec 2009 11:23:49 -0800 Original-Received: from faina.iro.umontreal.ca (faina.iro.umontreal.ca [132.204.26.177]) by chene.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id nB7JNkPW014551; Mon, 7 Dec 2009 14:23:46 -0500 Original-Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id 74B983A122; Mon, 7 Dec 2009 14:23:46 -0500 (EST) In-Reply-To: <87iqcjeq45.fsf@mail.jurta.org> (Juri Linkov's message of "Mon, 07 Dec 2009 19:27:34 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV3422=0 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Resent-Date: Mon, 07 Dec 2009 14:47:39 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:33374 Archived-At: > Using M-x shell in Emacs causes lossage in .bash_history. > I set HISTFILESIZE and HISTSIZE to large values in .bashrc > to not truncate the history file but comint.el disregards > my settings and truncates the history file used by bash. That's the bug, yes, thank you. > The following patch make `comint-input-ring-size' customizable. > The type should be `integer' because this value is used by `make-ring' > to create the history ring. The default value increased to 500 > to be the same as the default value of HISTFILESIZE and HISTSIZE. Actually, to fix the bug right, comint-read-input-ring should be changed to grow the ring so as to accomodate all the saved history. This might still truncate it more than bash would have, but at least it won't make your .bash_history shorter than it was. Stefan > Index: lisp/comint.el > =================================================================== > RCS file: /sources/emacs/emacs/lisp/comint.el,v > retrieving revision 1.402 > diff -c -r1.402 comint.el > *** lisp/comint.el 1 Dec 2009 20:32:00 -0000 1.402 > --- lisp/comint.el 7 Dec 2009 17:27:08 -0000 > *************** > *** 309,317 **** > :type 'integer > :group 'comint) > ! ;; FIXME: this should be defcustom > ! (defvar comint-input-ring-size 150 > ! "Size of input history ring.") > (defvar comint-input-ring-separator "\n" > "Separator between commands in the history file.") > --- 309,319 ---- > :type 'integer > :group 'comint) > ! (defcustom comint-input-ring-size 500 > ! "Size of input history ring." > ! :type 'integer > ! :group 'comint > ! :version "23.2") > (defvar comint-input-ring-separator "\n" > "Separator between commands in the history file.") > -- > Juri Linkov > http://www.jurta.org/emacs/