From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2666 invoked from network); 11 Aug 2005 11:37:55 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 11 Aug 2005 11:37:55 -0000 Received: (qmail 34814 invoked from network); 11 Aug 2005 11:37:48 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 11 Aug 2005 11:37:48 -0000 Received: (qmail 25009 invoked by alias); 11 Aug 2005 11:37:40 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 9292 Received: (qmail 24998 invoked from network); 11 Aug 2005 11:37:39 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 11 Aug 2005 11:37:39 -0000 Received: (qmail 33744 invoked from network); 11 Aug 2005 11:37:39 -0000 Received: from pantene.yandex.ru (213.180.200.35) by a.mx.sunsite.dk with SMTP; 11 Aug 2005 11:37:35 -0000 Received: from YAMAIL (pantene.yandex.ru) by mail.yandex.ru id ; Thu, 11 Aug 2005 15:37:19 +0400 Date: Thu, 11 Aug 2005 15:37:19 +0400 (MSD) From: "Artur Penttinen" Sender: arto-p@yandex.ru Message-Id: <42FB386F.000003.12074@pantene.yandex.ru> MIME-Version: 1.0 X-Mailer: Yamail [ http://yandex.ru ] Errors-To: arto-p@yandex.ru To: zsh-users@sunsite.dk Subject: Re: Some strange behavior of %~ In-Reply-To: <17079.1123753982@csr.com> Reply-To: arto-p@yandex.ru References: <42FAFC8D.000002.21101@mfront7.yandex.ru> <17079.1123753982@csr.com> X-Source-Ip: 192.100.124.219 X-Originating-Ip: 172.21.23.46 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00 autolearn=ham version=3.0.4 >"Artur Penttinen" wrote: >> # cd work >> # print -P "%~" >> ~/work >> # cd ../work >> # print -P "%~" >> /hipsohome/home/arpentti/work >> # print $ZSH_VERSION >> 4.2.5 >> # > >This is probably something to do with using an automounter. I would >guess that $HOME is /home/arpentti, right? On the second system, >this probably gets created as a link to /hipsohome/home/arpentti which >will be where the automounter mounts the directory. (Or the person >responsible just likes symbolic links.) Yes, You're right. # ls -l /home lrwxr-xr-x 1 root wheel 15 Aug 23 2004 /home@ -> /hipsohome/home # >Quite why the cd works that way I'm not sure, but it's possibly you >have the CHASE_LINKS option set, in which case the symbolic links are >resolved. But that obviously didn't happen with the first cd. > >Using both "pwd -L" and "pwd -P" (print logical and physical directory) >after each step might make it clearer. # [[ -o chaselinks ]] || print no no # Question: what i will set for proper behavior of `%~' ? Yes, I can set HOME=/hipsohome/home/arpentti, but imho, this is politically incorrect... -- wbw, artur penttinen