From a6348ad118c489d41053a9c6529a32ff7c2f7f39 Mon Sep 17 00:00:00 2001 From: madumlao Date: Thu, 25 Jun 2020 23:33:53 +0800 Subject: [PATCH] Add bash / zsh specific kubectl initialization commands to profile --- skel/.bash_profile | 5 +++++ skel/.zprofile | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/skel/.bash_profile b/skel/.bash_profile index b8e6424..deca165 100644 --- a/skel/.bash_profile +++ b/skel/.bash_profile @@ -7,3 +7,8 @@ if [ -n "$BASH_VERSION" ]; then fi source "$HOME/.profile" + +# source kubernetes shell completion +if [ "$PROFILE_ENABLE_KUBECTL" ]; then + source <(kubectl completion bash) +fi diff --git a/skel/.zprofile b/skel/.zprofile index d04b7d3..cee8ebf 100644 --- a/skel/.zprofile +++ b/skel/.zprofile @@ -1,2 +1,7 @@ source /etc/profile source $HOME/.profile + +# source kubernetes shell completion +if [ "$PROFILE_ENABLE_KUBECTL" ]; then + source <(kubectl completion zsh) +fi