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