help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Saving/Recalling Shell Commands History?


From: Peter Dyballa
Subject: Re: Saving/Recalling Shell Commands History?
Date: Mon, 21 Aug 2006 23:08:20 +0200


Am 21.08.2006 um 22:17 schrieb Drew Adams:

Although I have set comint-input-ring-file-name, this file never gets
    written.

Did you set it locally in the shell buffer (mode)? The doc string says this:

 "This variable is buffer-local, and is a good thing to
  set in mode hooks."

No. I found it in a *customise* buffer and set it there first.


What is the value of comint-input-ring-file-name in your shell buffer if you don't ever explicitly set it?


Now, edited to fit into a system of a handful Emacsen, it is set as:

        '(comint-input-ring-file-name (concat desktop-dirname "/history"))

Desktop-dirname is defined in .emacs. In recent GNU Emacs 23 the variable's value is described as:

        comint-input-ring-file-name is a variable defined in `comint.el'.
        Its value is "~/.history"
        Local in buffer *shell*; global value is
        "~/.emacs.d/PDesktop-23/history"
        Documentation:
        *If non-nil, name of the file to read/write input history.
        See also `comint-read-input-ring' and `comint-write-input-ring'.
        
This variable is buffer-local, and is a good thing to set in mode hooks.
        
        You can /customize/ this variable.

When I comment the comint-input-ring-file-name setting line, its value is simply "~/.history."

I retrieved the values by pasting comint-input-ring-file-name into *shell* buffer and pressing C-h v.

--
Greetings

  Pete

From error to error, one discovers the entire truth.
                                                     - Sigmund Freud






reply via email to

[Prev in Thread] Current Thread [Next in Thread]