diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2018-12-02 21:52:21 +1300 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2018-12-02 21:52:21 +1300 |
commit | 7464165197bbd1fd43a24c84ef3f94cadcdd4be7 (patch) | |
tree | 6108e80645e008394f3540fca5b8caa8d71b8bc3 /bash | |
parent | Make `sec` a local var in man page completion (diff) | |
download | dotfiles-7464165197bbd1fd43a24c84ef3f94cadcdd4be7.tar.gz dotfiles-7464165197bbd1fd43a24c84ef3f94cadcdd4be7.zip |
Update glob settings for manual page completion
Diffstat (limited to 'bash')
-rw-r--r-- | bash/bash_completion.d/man.bash | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/bash/bash_completion.d/man.bash b/bash/bash_completion.d/man.bash index 31be9a95..4326c48a 100644 --- a/bash/bash_completion.d/man.bash +++ b/bash/bash_completion.d/man.bash @@ -24,20 +24,12 @@ _man() { COMPREPLY[ci++]=$comp done < <( - # Do not return dotfiles, give us extended globbing, and expand empty - # globs to just nothing + # Make globs expand appropriately shopt -u dotglob shopt -s nullglob - - # Make globbing case-insensitive if appropriate - while read -r _ setting ; do - case $setting in - ('completion-ignore-case on') - shopt -s nocaseglob - break - ;; - esac - done < <(bind -v) + if _completion_ignore_case ; then + shopt -s nocaseglob + fi # Figure out the manual paths to search if hash amanpath 2>/dev/null ; then |