From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25710 invoked from network); 19 Apr 2001 22:28:08 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 19 Apr 2001 22:28:08 -0000 Received: (qmail 5641 invoked by alias); 19 Apr 2001 22:27:28 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 3826 Received: (qmail 5625 invoked from network); 19 Apr 2001 22:27:27 -0000 Date: Fri, 20 Apr 2001 01:27:25 +0300 From: Juhapekka Tolvanen To: zsh-users mailing list Subject: [schaefer@candle.brasslantern.com: Re: How to exploit chpwd-function?] Message-ID: <20010420012725.A4486@silmu.st.jyu.fi> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit User-Agent: Mutt/1.2.5i Organization: =?iso-8859-1?Q?Overhovel_of_Jyv=E4skyl=E4?= X-URL: http://www.cc.jyu.fi/~juhtolv/ X-Mailer-URL: http://www.mutt.org/ X-Editor: Vim http://www.vim.org/ X-Operating-System: Linux 2.2.16 on an i686 Bart forgot to send his answer to this list, too: Anyway, those ways to exploit chpwd sounds so cool that I think I'll add some stuff of that kind to my shell-configs some day. ----- Forwarded message from Bart Schaefer ----- From: "Bart Schaefer" Message-Id: <1010419025502.ZM8775@candle.brasslantern.com> Date: Thu, 19 Apr 2001 02:55:01 +0000 In-Reply-To: <20010418192521.A20505@silmu.st.jyu.fi> References: <20010418192521.A20505@silmu.st.jyu.fi> To: Juhapekka Tolvanen Subject: Re: How to exploit chpwd-function? Content-Length: 1349 Lines: 34 On Apr 18, 7:25pm, Juhapekka Tolvanen wrote: } Subject: How to exploit chpwd-function? } } Need I say more? Would you please tell me your favourite ways to use } chpwd-function. } } P.S: I do not subscribe to this list, but I am smart enough to read } mailing-list archives via WWW. You can Cc: to me, if I want. A search on chpwd in the zsh-users archive gives 73 hits, covering only three topics (aside from bug reports): using chpwd to set the xterm title (and similar stunts) [better done with precmd, but see also the zftp_chpwd function in the 3.1.9 and later zsh manual]; using chpwd to save and load a per-directory zsh history; using chpwd to report whether the new $PWD is a symlink. A search on zsh-workers turns up nothing else of interest. In the past, I've used chpwd to check whether the .exrc file in the current directory could safely be read and set EXINIT accordingly; but as I now use emacs more often than vi, I've dropped that. The only thing left in my chpwd function now is assigning cwd=$PWD, because I first learned csh and still occasionally type $cwd by "mistake." -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net ----- End forwarded message ----- -- Juhapekka "naula" Tolvanen * U of Jyväskylä * * juhtolv@st.jyu.fi http://www.st.jyu.fi/~juhtolv/spam.html * STRAIGHT BUT NOT NARROW ----------------------------------------------------------------- "There's a new game we like to play, you see, a game with added reality. You treat me like a dog. Get me down on my knees. We call it 'Master and servant'." Depeche Mode