After installing kubernetes-cli via homebrew in a mac with zsh, the kubernetes auto complete is not working completely or in full. Only the first tab works and not the second tab onwards. Example, if I type kubectl [TAB]
, it displays the sub commands for kubectl
, and now if I select a sub command and press [TAB], eg kubectl get [TAB]
, it freezes for a lot of time and nothing happens there after.
I tried the following ways
- Installed kubectl-cli via home brew
- enabled zsh plugin
- added the below code as well
source <(kubectl completion zsh) autoload -Uz compinit compinit