aboutsummaryrefslogtreecommitdiff
path: root/bash/bash_completion.d/pass.bash
diff options
context:
space:
mode:
Diffstat (limited to 'bash/bash_completion.d/pass.bash')
-rw-r--r--bash/bash_completion.d/pass.bash14
1 files changed, 14 insertions, 0 deletions
diff --git a/bash/bash_completion.d/pass.bash b/bash/bash_completion.d/pass.bash
index feff78ae..e697f5d1 100644
--- a/bash/bash_completion.d/pass.bash
+++ b/bash/bash_completion.d/pass.bash
@@ -23,6 +23,20 @@ _pass()
shopt -u dotglob
shopt -s globstar nullglob
+ # Make globbing case-insensitive if appropriate; is there a cleaner way
+ # to find this value?
+ while read -r _ option value ; do
+ case $option in
+ completion-ignore-case)
+ case $value in
+ on)
+ shopt -s nocaseglob
+ break
+ ;;
+ esac
+ esac
+ done < <(bind -v)
+
# Gather the entries and remove their .gpg suffix
declare -a entries
entries=("$passdir"/"${COMP_WORDS[COMP_CWORD]}"*/**/*.gpg \