File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
argcomplete/bash_completion.d Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -115,7 +115,6 @@ __python_argcomplete_which() {
115
115
}
116
116
117
117
_python_argcomplete_global() {
118
-
119
118
if [[ -n "${ZSH_VERSION-}" ]]; then
120
119
# Store result of a regex match in the
121
120
# BASH_REMATCH variable rather than MATCH
@@ -237,8 +236,8 @@ if [[ -z "${ZSH_VERSION-}" ]]; then
237
236
complete -o default -o bashdefault -D -F _python_argcomplete_global
238
237
else
239
238
autoload is-at-least
240
- # Replace only the default completer (_default) .
241
- # There are many other special contexts we don't want to override.
239
+ # Set a hook for argcomplete to be called first if no other completers are defined for the given command .
240
+ # "compdef _python_argcomplete_global -P *" overrides other special contexts that we want to preserve:
242
241
# https://zsh.sourceforge.io/Doc/Release/Completion-System.html
243
- compdef _python_argcomplete_global -default -
242
+ compdef _python_argcomplete_global -first -
244
243
fi
You can’t perform that action at this time.
0 commit comments