Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: history trouble



On Sun, 29 Jan 2006, Thomas Richter wrote:

Greetings, Thomas,
  Can you verify something:
  Start a shell, enter a few commands, exit the shell, then look at the
history file and see if your commands were added to it?  If so, then
it's not a matter of your commands not being written to history, but that
they are being buffered and, upon exit, flushed to file.

Try this:
  setopt inc_append_history

Hi Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>,
you wrote on Saturday, 2006-01-28 20:32:36 +0000:
On Jan 28,  8:04pm, Thomas Richter wrote:

Possible reasons for the history not to be read are:

- the NO_RCS option is set (the doc says this prevents history from
  being written, but it also suppresses reading it)

This option is not set.

- the INTERACT option is not set

This option is set.

- lockhistfile() fails because
  + a temporary lock file can't be created in the same directory
    as the HISTFILE

How can I test this?

  + a link to that temp file can't be created

ln -s $HISTFILE newname is ok

  + something else [possibly several somethings] has the file locked
    for more than about 10 seconds (but this shouldn't apply at shell
    startup, only for incremental history)

no process has this file open

- the file can't be opened for reading

cat $HISTFILE is ok

- some part of the file is corrupt

no contains only one line with one word

- HISTSIZE is zero (in which case, I believe, the file is read but all
  the contents are discarded)

HISTSIZE = 99999

My (new, ahem) guess is that the problem is with the lock file.

wkr Thomas Richter

--
Peter A. Castro <doctor@xxxxxxxxxxxx> or <Peter.Castro@xxxxxxxxxx>
	"Cats are just autistic Dogs" -- Dr. Tony Attwood



Messages sorted by: Reverse Date, Date, Thread, Author