Move kubectl init

This commit is contained in:
Buddy Sandidge 2020-12-13 18:44:34 -08:00
parent b6271e122e
commit c19e79600a
2 changed files with 10 additions and 2 deletions

View File

@ -4,5 +4,3 @@
if [ -f "$(brew --prefix)/share/bash-completion/bash_completion" ]; then
. "$(brew --prefix)/share/bash-completion/bash_completion"
fi
source <(kubectl completion bash)

View File

@ -0,0 +1,10 @@
#ft=sh
#shellcheck disable=1090,2039
if [ "${BASH_VERSION}" != "" ] && [ "$(ps -p $$ -ocomm=)" != sh ]; then
source <(kubectl completion bash)
fi
if [ "${ZSH_VERSION}" != "" ]; then
source <(kubectl completion zsh)
fi