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

Re: Question about the Zsh History event number

If you are using a saved history each time you start a zsh session the old 
history gets imported. The numbering continues. You can use old event numbers 
in you new session if you like.

There are some options how you can control the history behavior. 

Furthermore zsh has the ability to share it's history across multiple running 
sessions. Each command get's it's own event number. You can recall the command 
with event number 123 entered in zsh session 1 from zsh session 2 by using the 
history command "!123".

On Thursday, 8. April 2010 18:18:54 Vikas Mishra wrote:
> Hello Folks,
> I am new to Zsh (have moved to Zsh recently from BASH). I am loving it
> so far. I was playing around with my prompt. I have set the PROMPT
> variable as
> export PROMPT="[%m %h] %1d  > "
> I have one small issue, the history event number is not resetting to 1
> when I start a new shell. Is this expected (at least in BASH this used
> to reset to 1 in a new shell).
> Any suggestions ? Thanks for your help.
> Regards,
> Vikas

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