Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Wierd autoload problems with nested directories
- X-seq: zsh-workers 21330
- From: Ulf Magnusson <ulfalizer@xxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: Wierd autoload problems with nested directories
- Date: Tue, 14 Jun 2005 02:55:59 +0200
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=oaG/9nw7WEtY48x7e4s3JiwOsDTumrsLATBrT7DYc+cqjd22BKd1APFtk4u5d8o0hlXEtXpEHoTKfPBFFCwBSLccs08opwoH4B0tNnzHn0DYscl1A3AUcgdW6DJbk+eXHNEFiYybQZi2mL64zfX5wjmAPLk3PtUmHyPxHDfUrXo=
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- Reply-to: Ulf Magnusson <ulfalizer@xxxxxxxxx>
I keep my completion functions in /home/ulf/lib/zsh/completions and
other, general-purpose functions in its parent dir, /home/ulf/lib/zsh.
For some reason, my completions will only work ('work' as in zsh not
using its default completion behaviour for the context in question) if
I place them in /home/ulf/lib/zsh.
I set the completion and other functions up for autoloading in two
sections of my .zshrc with the following code:
fpath=(/home/ulf/lib/zsh/completions $fpath)
autoload -U $fpath[1]/*(:t)
fpath=(/home/ulf/lib/zsh $fpath)
autoload -U $fpath[1]/*(:t)
print -l ${fpath[1,3]} yields
/home/ulf/lib/zsh/completions
/home/ulf/lib/zsh
/usr/local/share/zsh/site-functions
, as expected. I do not have KSH_AUTOLOAD nor any other options I
imagine could cause this problem set. My completion function (the only
one so far), stored in the file /home/ulf/lib/zsh/completions/_xmms
looks as follows:
#compdef xmms
local directories
directories=( /s/Music/**/(/) )
_files -W directories -g '*.(mp3|ogg)'
(It's not done yet, do not bug me about it :) )
Ulf
Messages sorted by:
Reverse Date,
Date,
Thread,
Author