mirror of https://github.com/pypa/pip
Fix #12166
- tests expected results indendation was off - add bugfix news entry
This commit is contained in:
parent
b551c09c4e
commit
dba399fe6a
|
@ -0,0 +1 @@
|
|||
Fix completion script for zsh
|
|
@ -23,9 +23,18 @@ COMPLETION_SCRIPTS = {
|
|||
""",
|
||||
"zsh": """
|
||||
#compdef -P pip[0-9.]#
|
||||
__pip() {{
|
||||
compadd $( COMP_WORDS="$words[*]" \\
|
||||
COMP_CWORD=$((CURRENT-1)) \\
|
||||
PIP_AUTO_COMPLETE=1 $words[1] 2>/dev/null )
|
||||
}}
|
||||
if [[ $zsh_eval_context[-1] == loadautofunc ]]; then
|
||||
# autoload from fpath, call function directly
|
||||
__pip "$@"
|
||||
else
|
||||
# eval/source/. command, register function for later
|
||||
compdef __pip -P 'pip[0-9.]#'
|
||||
fi
|
||||
""",
|
||||
"fish": """
|
||||
function __fish_complete_pip
|
||||
|
|
|
@ -44,9 +44,18 @@ complete -fa "(__fish_complete_pip)" -c pip""",
|
|||
"zsh",
|
||||
"""\
|
||||
#compdef -P pip[0-9.]#
|
||||
compadd $( COMP_WORDS="$words[*]" \\
|
||||
__pip() {
|
||||
compadd $( COMP_WORDS="$words[*]" \\
|
||||
COMP_CWORD=$((CURRENT-1)) \\
|
||||
PIP_AUTO_COMPLETE=1 $words[1] 2>/dev/null )""",
|
||||
PIP_AUTO_COMPLETE=1 $words[1] 2>/dev/null )
|
||||
}
|
||||
if [[ $zsh_eval_context[-1] == loadautofunc ]]; then
|
||||
# autoload from fpath, call function directly
|
||||
__pip "$@"
|
||||
else
|
||||
# eval/source/. command, register function for later
|
||||
compdef __pip -P 'pip[0-9.]#'
|
||||
fi""",
|
||||
),
|
||||
(
|
||||
"powershell",
|
||||
|
|
Loading…
Reference in New Issue