Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Tip of the day: automounted home directories
- X-seq: zsh-users 9718
- From: Peter Stephenson <pws@xxxxxxx>
- To: zsh-users@xxxxxxxxxx (Zsh users list)
- Subject: Tip of the day: automounted home directories
- Date: Wed, 30 Nov 2005 13:14:37 +0000
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
Here's how to get completion for home directories under /home which are
handled by the automounter, assuming the automounter is using
/etc/auto.home:
homes=($(awk '$1 !~ /^#/ { print $1 }' /etc/auto.home))
zstyle ':completion:*' fake-files "/home:$homes"
unset homes
If the automounter is using the NIS map auto.home, change the first line
to:
homes=($(ypcat -k auto.home | awk '{ print $1 }'))
--
Peter Stephenson <pws@xxxxxxx> Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070
This message has been scanned for viruses by BlackSpider MailControl - www.blackspider.com
Messages sorted by:
Reverse Date,
Date,
Thread,
Author