Quick script that I can drop in to set up kubectl completion and aliases etc
wget -q -O - https://gist.githubusercontent.com/stuartleeks/29e58601de67f270f27ee240d7b0a5e3/raw/setup.sh | bash| apt-get update && apt-get install bash-completion | |
| source /etc/bash_completion | |
| alias cd..="cd .." | |
| alias cls=clear | |
| alias md=mkdir | |
| source <(kubectl completion bash) | |
| alias k=kubectl | |
| # source <(k completion bash | sed s/kubectl/k/g) | |
| complete -o default -F __start_kubectl k | |
| export KUBE_EDITOR="code --wait" | |
| git clone https://github.com/ahmetb/kubectx.git /root/.kubectx \ | |
| && COMPDIR=$(pkg-config --variable=completionsdir bash-completion) \ | |
| && ln -sf /root/.kubectx/completion/kubens.bash $COMPDIR/kubens \ | |
| && ln -sf /root/.kubectx/completion/kubectx.bash $COMPDIR/kubectx | |
| export PATH="/root/.kubectx:${PATH}" |