Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Named directory pointing to a symbolic link
- X-seq: zsh-users 9546
- From: Jean Chalard <jean.chalard@xxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Named directory pointing to a symbolic link
- Date: Mon, 24 Oct 2005 13:04:48 +0900
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=ck5wTyDuD32/78Sxs5rIma0dlz/NYrekU+jqUrg1jgSWuMlY+vu2iTCXP8739h1HKeZi3fcdGWYlyWIquoZFYwGB0MR5CA112BoqoFluvHgALLUYBTXdUURuRUBp0OI8q7/Lf7iio+SguCaxyOXclm0JIhstSx8FkhmL/6K6YZo=
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
Hi zusers,
I've run into a behaviour I wasn't expecting with named directories on
FreeBSD. It's not like its a real inconvenience, but I thought I'd ask
anyway because I didn't find anything about this in the manual.
It seems to me like the 'www' variable (which ought to be unset when I
start the shell, it's not like it should be a special variable as far
as I understand) has a strange behaviour : it points on /nonexistent
when used as a named directory, and any attempt I do to have it point
elsewhere with the export builtin doesn't work when the variable is
used as a named directory, though it works when invoked as hash -d.
Other variable names don't seem to behave that way.
The script you see below is executed on a machine on which I installed
zsh in my user account, but I don't think it could be relevant because
I can reproduce it on another FreeBSD where zsh is installed the
vanilla way and where I don't have any configuration files. This
doesn't happen on the linux box I have my hands on at the moment,
where the www variable behaves exactly the same way as the foo
variable. It happens that I can't test on other systems I usually have
access to at the moment, sorry :/
To clarify what I mean :
> zsh/bin/zsh -f
mobdev% zsh/bin/zsh --version
zsh 4.2.5 (i386-unknown-freebsd4.11)
mobdev% uname -a
FreeBSD mobdev 4.11-STABLE FreeBSD 4.11-STABLE #1: Tue Feb 22 05:55:23 JST 2005
root@:/usr/src/sys/compile/WDB i386
mobdev% autoload -U parameters
mobdev% echo $nameddirs
mobdev% echo ~foo
zsh: no such user or named directory: foo
mobdev% echo $www
mobdev% echo ~www
/nonexistent
mobdev% export www=/usr
mobdev% echo $www
/usr
mobdev% echo ~www
/nonexistent
mobdev% hash -d www=/usr
mobdev% echo $www
/usr
mobdev% echo ~www
/usr
mobdev%
Does anyone have an idea of why this variable behaves that way ?
--
J
"Toi, je te trouve pas la même tête que sur la page précédente" -- Wakamiya
Messages sorted by:
Reverse Date,
Date,
Thread,
Author