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

Re: History corruption (over NFS)



On Mon, Feb 14, 2005 at 02:06:12PM -0700, Seth Kurtzberg wrote:
> Won't this cause problems in the mode where history is shared, and 
> history is written for every command

Nope -- appended history still appends just fine.  As mentioned, zsh
re-opens the history file for every append, so it matters not if the
file gets rewritten to a new inode.  Also, every append and every
rewrite is locked by using a .zhistory.LOCK file, so multiple shells
don't update the history file at the same time.

> not just once when the shell terminates?

Zsh also periodically rewrites the history file when the number of
appended lines exceeds the SAVEHIST count by a certain percentage.

..wayne..



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