]> git.phdru.name Git - dotfiles.git/commitdiff
.shellrc: Fix shell syntax
authorOleg Broytman <phd@phdru.name>
Fri, 13 Oct 2017 17:23:11 +0000 (20:23 +0300)
committerOleg Broytman <phd@phdru.name>
Fri, 13 Oct 2017 17:23:11 +0000 (20:23 +0300)
Read completion files one by one.

.shellrc

index 8d63ee79e55df1d256f35ba0ecfd64760faa5fb2..ff0e12710ff3fc9a9c74cf8083897a9f38d1fb53 100644 (file)
--- a/.shellrc
+++ b/.shellrc
@@ -76,11 +76,15 @@ if test -n "$BASH_VERSION"; then
          if [ -f /etc/bash_completion ]; then
             . /etc/bash_completion
          elif [ -d /etc/bash_completion.d ]; then
-            . /etc/bash_completion.d/*
+            for _compf in /etc/bash_completion.d/*; do
+               . $_compf
+            done
          fi
       elif [ "$SHELL" = /usr/local/bin/bash ]; then
          if [ -d /usr/local/etc/bash_completion.d ]; then
-            . /usr/local/etc/bash_completion.d/*
+            for _compf in /usr/local/etc/bash_completion.d/*; do
+               . $_compf
+            done
          fi
       else
          echo "Unknown OS type, cannot source bash_completion" >&2