aboutsummaryrefslogtreecommitdiff
path: root/bash
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2015-11-16 12:39:55 +1300
committerTom Ryder <tom@sanctum.geek.nz>2015-11-16 12:39:55 +1300
commit6f201da3c64823d657fe9973aecfc1684649f378 (patch)
tree101990233fe52329b62df7cde7a75d53e105b878 /bash
parentUse consistent apostrophe'’s (diff)
downloaddotfiles-6f201da3c64823d657fe9973aecfc1684649f378.tar.gz
dotfiles-6f201da3c64823d657fe9973aecfc1684649f378.zip
Only complete vis(1) args as filenames
Diffstat (limited to 'bash')
-rw-r--r--bash/bashrc.d/vis.bash2
1 files changed, 1 insertions, 1 deletions
diff --git a/bash/bashrc.d/vis.bash b/bash/bashrc.d/vis.bash
index 23c1199d..02981afe 100644
--- a/bash/bashrc.d/vis.bash
+++ b/bash/bashrc.d/vis.bash
@@ -12,7 +12,7 @@ _vis() {
files=("${VISPATH:-$HOME/.local/bin}"/"${COMP_WORDS[COMP_CWORD]}"*)
declare -a executables
for file in "${files[@]}" ; do
- [[ -x $file ]] || continue
+ [[ -f $file && -x $file ]] || continue
executables=("${executables[@]}" "${file##*/}")
done
((${#executables[@]})) || exit 1