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

Re: pushd



On Oct 15,  2:45pm, Peter Stephenson wrote:
} Subject: Re: pushd
}
} "Bart Schaefer" wrote:
} > Is the following more like the behavior you want?
} 
} Well, if I adapt your suggestion to:
} 
} pushd () {
}         setopt localoptions globsubst
}         unsetopt ksharrays
[...]
} }
} 
} (since I need ~ expansion and I don't want to count entry 0 from dirs
} in the array indexing)

Tilde expansion?  Oh, yeah, I forgot that dirstack entries (or rather,
"dirs" output) are tilde-abbreviated.  I wasn't anywhere near my home
directory when I was playing with this.

} I seem to get basically what I want.  It's yet
} another case of running very hard to stay in the same place.

Yes, I certainly know how you feel.  Most of the contents of my .z*
files are there just to help me lean into the hurricane.

I'd never noticed the (previous) discrepancy between zsh and csh/bash
directory stack behavior, and I'd similarly not yet noticed the change,
because I long ago took to opening a new xterm anytime I'll be spending
more than a few seconds in another directory.  So my stack never gets
more than about 3 entries deep.  But I've done plenty of my own griping
about changes made to features that other people didn't use/notice.

I'm with you for a PUSHD_CYCLE option, set by default, which when not
set would give the old zsh behavior.

Is the following the ChangeLog entry for pushd becoming cyclic?  Has it
really been that long ago?

        March/April 1995

        * pushd/popd changes from Anthony Heading <aheading@xxxxxxxxxxxx>



-- 
Bart Schaefer                             Brass Lantern Enterprises
http://www.well.com/user/barts            http://www.nbn.com/people/lantern

New male in /home/schaefer:
>N  2 Justin William Schaefer  Sat May 11 03:43  53/4040  "Happy Birthday"



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