diff options
author | David Lord <davidism@gmail.com> | 2021-12-28 12:09:24 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-28 12:09:24 -0700 |
commit | 4a21666a4e3705083ab41509381fe50fdc68a467 (patch) | |
tree | 6b1f0e0535955cf5ac0e990c32e86f4ac37fb41a | |
parent | 6987b4cdffcd995b991b7267344e938510bf7d33 (diff) | |
parent | 6f33518a82a21eb33894674501b0a04489f9c1be (diff) | |
download | click-4a21666a4e3705083ab41509381fe50fdc68a467.tar.gz |
Merge pull request #2163 from ashwin153/patch-1
Use COMPREPLY instead of COMREPLY in Bash shell completion
-rw-r--r-- | CHANGES.rst | 3 | ||||
-rw-r--r-- | src/click/shell_completion.py | 4 |
2 files changed, 5 insertions, 2 deletions
diff --git a/CHANGES.rst b/CHANGES.rst index cfc9280..6348d6f 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -11,6 +11,9 @@ Unreleased annotation of the decorated function. :pr:`2155` - A callable default value can customize its help text by overriding ``__str__`` instead of always showing ``(dynamic)``. :issue:`2099` +- Fix a typo in the Bash completion script that affected file and + directory completion. If this script was generated by a previous + version, it should be regenerated. :issue:`2163` Version 8.0.3 diff --git a/src/click/shell_completion.py b/src/click/shell_completion.py index cad080d..1e9df6f 100644 --- a/src/click/shell_completion.py +++ b/src/click/shell_completion.py @@ -102,10 +102,10 @@ _SOURCE_BASH = """\ IFS=',' read type value <<< "$completion" if [[ $type == 'dir' ]]; then - COMREPLY=() + COMPREPLY=() compopt -o dirnames elif [[ $type == 'file' ]]; then - COMREPLY=() + COMPREPLY=() compopt -o default elif [[ $type == 'plain' ]]; then COMPREPLY+=($value) |