From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15270 invoked from network); 21 Jun 2002 23:12:06 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 21 Jun 2002 23:12:06 -0000 Received: (qmail 26821 invoked by alias); 21 Jun 2002 23:11:55 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 5082 Received: (qmail 26808 invoked from network); 21 Jun 2002 23:11:55 -0000 Date: Fri, 21 Jun 2002 18:11:50 -0500 From: Dan Nelson To: zsh-users@sunsite.dk Subject: Re: howto avoid ~irc in %~ ? Message-ID: <20020621231150.GA59715@dan.emsphone.com> References: <1020615232225.ZM2169@candle.brasslantern.com> <20020621175139.A16301@radiomaranon.org.pe> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020621175139.A16301@radiomaranon.org.pe> X-OS: FreeBSD 5.0-CURRENT X-message-flag: Outlook Error User-Agent: Mutt/1.5.1i In the last episode (Jun 21), Andy Spiegl said: > Hi Bart and Wayne, > > I was really surprised to read this: > > > Zsh doesn't do this all by itself. You must at some point have used ~irc > > > before zsh would add an entry for irc to its hash table of named dirs. > because I never use ~irc. > > But Waynes comment explains it: > > Completing ~ names will also add it for you. For instance, if I type > > "~w" and get "~wayne", all other user home dirs have now been > > cached. > > So I guess there is no way to avoid ~irc to appear instead of /var. > Hm, unless I remove it from the cache. But how would I do that??? How about chpwd() { unhash -d irc } This lets you still use ~irc if you want, but by the time zsh gets around to parsing %~, it'll be out of the hash. -- Dan Nelson dnelson@allantgroup.com