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

Re: persistant Directory history?



On Mon, Nov 06, 2006 at 10:15:26PM +0530, chesss wrote:
> Is it possible to have some kind of directory history, taht would last
> after closing the shell?
[...]

I have in ~/.zshrc:

SAVED_DIRSTACK=~/.zsh-dir-stack
[[ -f $SAVED_DIRSTACK ]] && . $SAVED_DIRSTACK
trap '
  print -r "dirstack=(${(@qq)dirstack})" > $SAVED_DIRSTACK
' EXIT

-- 
Stéphane



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