Skip to content

Instantly share code, notes, and snippets.

@jpts
Last active September 6, 2022 23:16
Show Gist options
  • Save jpts/318546e5665241656577accce34ff387 to your computer and use it in GitHub Desktop.
Save jpts/318546e5665241656577accce34ff387 to your computer and use it in GitHub Desktop.
kubectl bash completion
cat <<EOF >> ~/.bashrc
source <(kubectl completion bash)
alias k=kubectl
complete -o default -F __start_kubectl k
EOF
source /etc/profile.d/bash_completion.sh
source ~/.bashrc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment