10 lines
207 B
Plaintext
10 lines
207 B
Plaintext
|
#!/usr/bin/env sh
|
||
|
kubectl config get-contexts --no-headers | \
|
||
|
uniq | \
|
||
|
sort | \
|
||
|
tr -s ' ' | \
|
||
|
sed -E 's/^\*?[[:space:]]*//g' | \
|
||
|
cut -d ' ' -f1 | \
|
||
|
fzf | \
|
||
|
xargs -I{} kubectl config use-context '{}'
|