Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Tiny patch to module command completion



Hi,

please apply the attached tiny patch to fix a thinko/typo in module
command completion, it changes "grep -v \.version" to "grep -v
\\.version". Without it modules containing regexp .version won't show
up in completion list (e.g., subversion).

Thanks.




       
____________________________________________________________________________________
Moody friends. Drama queens. Your life? Nope! - their life, your story. Play Sims Stories at Yahoo! Games.
http://sims.yahoo.com/  
--- zsh/Completion/Unix/Command/_module.orig
+++ zsh/Completion/Unix/Command/_module
@@ -85,7 +85,7 @@
 {
   if [[ -n $MODULEPATH ]] && [[ ${+_available_modules} -eq 0 ]]
   then
-    _available_modules=($(find ${(e)=MODULEPATH//:/ } -xtype f -print 2>/dev/null | grep -v \.version | sed -e 's,\('${${(e)=MODULEPATH//:/\/\\\|}%\\\|}'\),,g' -e 's,^/*,,g'))
+    _available_modules=($(find ${(e)=MODULEPATH//:/ } -xtype f -print 2>/dev/null | grep -v \\.version | sed -e 's,\('${${(e)=MODULEPATH//:/\/\\\|}%\\\|}'\),,g' -e 's,^/*,,g'))
   fi
 }
 


Messages sorted by: Reverse Date, Date, Thread, Author