From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2570 invoked from network); 29 Oct 1998 12:27:45 -0000 Received: from math.gatech.edu (list@130.207.146.50) by ns1.primenet.com.au with SMTP; 29 Oct 1998 12:27:45 -0000 Received: (from list@localhost) by math.gatech.edu (8.9.1/8.9.1) id HAA06186; Thu, 29 Oct 1998 07:17:21 -0500 (EST) Resent-Date: Thu, 29 Oct 1998 07:17:15 -0500 (EST) Message-Id: <9810299096.AA909663631@smtp-gw.jeppesen.com> X-Mailer: ccMail Link to SMTP R8.00.00 Date: Thu, 29 Oct 98 13:18:01 -0700 From: "G. Khalsa" To: Subject: Completion of cd type functions? MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Resent-Message-ID: <"XZ_I4.0.CW1.Ap5Es"@math> Resent-From: zsh-users@math.gatech.edu X-Mailing-List: archive/latest/1889 X-Loop: zsh-users@math.gatech.edu X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu Hi, I just switched from tcsh to zsh. In tcsh I frequently defined aliases to cd directly to various directories and used completion to move further from these directories: Example: alias cxxsrc 'cd ~/development/source/cxx/\!*' complete cxxsrc "p@1@D:$HOME/development/source/cxx@" This way I can just type cxxsrc from anywhere and have it complete only with directories in $HOME/development/source/cxx. Can I do this somehow in zsh (simply)? This seems pretty basic (it isn't even a FAQ) but I can't figure it out. I got it to sort of work using a function that invokes "find" but it is deadly slow. As far as I understand it I create a function: cxxsrc() { cd $HOME/development/source/cxx/$* } but the completion part eludes me. Unfortunately the lete2ctl script fails when I try to run it so I can't get all my nifty tcsh completions translated automatically. Thanks Gurutej Khalsa