Optionally load kubernetes completions

This commit is contained in:
Paweł Płazieński 2019-12-31 08:50:36 +01:00
parent 8329d2df02
commit 74f57b9ecf

5
zshrc
View File

@ -670,4 +670,9 @@ store_last_return_value() {
# This must be exactly first precmd function, because other precmd might modify $?
precmd_functions=(store_last_return_value $precmd_functions)
# If kubectl is present, load completions from it.
# This must be done after compinit was called
if [[ $commands[kubectl] ]]; then
source <(kubectl completion zsh);
fi