1
0
Fork 0

zsh: fix kubectl context

This commit is contained in:
Von Random 2024-10-18 22:46:01 +03:00
parent b62f8e262f
commit 53cdf4c643

View file

@ -48,7 +48,7 @@ precmd.has_kube() {
}
precmd.kube_context() {
typeset kube_context=$(awk '($1 ~ "^current") {print $2}' $kube_config)
typeset kube_context=$(awk -F- '($1 == "current") {print $3}' $kube_config)
precmd.prompt.add $prompt_symbols[helm]
precmd.prompt.add $kube_context $prompt_colors[kube_context]
}