Set nocaseglob on cygwin.
[profile.git] / .profile.d / completion.bashrc
index cf77c15..90db89c 100644 (file)
@@ -30,8 +30,7 @@ function _process() {
 function _known_hosts() {
   cur=${COMP_WORDS[COMP_CWORD]}
 
-  HOSTS=$(sed 's/[      ].*//;s/,/\
-/' ~/.ssh/known_hosts)
+  HOSTS=$(sed 's/[      ].*//;s/,/\n/' ~/.ssh/known_hosts)
 
   COMPREPLY=($(compgen -W "$HOSTS" -- "$cur"))
   return 0
@@ -86,7 +85,7 @@ function _modprobe() {
   COMPREPLY=()
   cur=${COMP_WORDS[COMP_CWORD]}
 
-  ver=$(uname -r)
+  ver=$KERNEL
   MODULES="$(find /lib/modules/$ver -name \*.ko | sed -n 's@^.*/\([^/]*\).ko$@\1@p')"
 
   COMPREPLY=($(compgen -W "$MODULES" -- "$cur"))