mirror of
https://github.com/sharkdp/bat.git
synced 2025-10-30 14:43:57 +00:00
Disable completion of cache subcommand (#2399)
* Disable completion of `cache` subcommand * Fully removed completion code for `cache` * Add to changelog
This commit is contained in:
26
assets/completions/bat.zsh.in
vendored
26
assets/completions/bat.zsh.in
vendored
@@ -80,20 +80,14 @@ _{{PROJECT_EXECUTABLE}}_main() {
|
||||
esac
|
||||
}
|
||||
|
||||
# first positional argument
|
||||
if (( ${#words} == 2 )); then
|
||||
local -a subcommands
|
||||
subcommands=('cache:Modify the syntax-definition and theme cache')
|
||||
_describe subcommand subcommands
|
||||
_{{PROJECT_EXECUTABLE}}_main
|
||||
else
|
||||
case $words[2] in
|
||||
cache)
|
||||
_{{PROJECT_EXECUTABLE}}_cache_subcommand
|
||||
;;
|
||||
case $words[2] in
|
||||
cache)
|
||||
## Completion of the 'cache' command itself is removed for better UX
|
||||
## See https://github.com/sharkdp/bat/issues/2085#issuecomment-1271646802
|
||||
_{{PROJECT_EXECUTABLE}}_cache_subcommand
|
||||
;;
|
||||
|
||||
*)
|
||||
_{{PROJECT_EXECUTABLE}}_main
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
*)
|
||||
_{{PROJECT_EXECUTABLE}}_main
|
||||
;;
|
||||
esac
|
||||
|
||||
Reference in New Issue
Block a user