Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: directory alias
- X-seq: zsh-workers 32090
- From: Christian Neukirchen <chneukirchen@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: directory alias
- Date: Wed, 04 Dec 2013 19:02:24 +0100
- In-reply-to: <CAH_OBidDmzECfgLVcEUmRj2+bean+WjuBvgiPV6SoE9i0kPfKA__21315.6334394172$1386127558$gmane$org@mail.gmail.com> (shawn wilson's message of "Tue, 3 Dec 2013 22:21:53 -0500")
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CAH_OBidDmzECfgLVcEUmRj2+bean+WjuBvgiPV6SoE9i0kPfKA__21315.6334394172$1386127558$gmane$org@mail.gmail.com>
- Sender: chris@juno
shawn wilson <ag4ve.us@xxxxxxxxx> writes:
> not sure if this is really a 'zsh thing' but I'm looking for a way to
> create aliases for a command. I don't want a bunch of symlinks in my
> home directory, and I don't want a universal alias for each directory
> I commonly cd into. What I want is a way to do:
> cd foo
> and it go to ~/some/deep/directory/tree/foo
> and
> cd bar
> and it go to /usr/local/some/path/bar
The obvious solution:
juno% setopt CDABLE_VARS
juno% bar=/usr/local/bin
juno% cd bar
~bar
juno% pwd
/usr/local/bin
--
Christian Neukirchen <chneukirchen@xxxxxxxxx> http://chneukirchen.org
Messages sorted by:
Reverse Date,
Date,
Thread,
Author