From d26c143e8ad61ecf7a09058ded785a447214c052 Mon Sep 17 00:00:00 2001 From: himkt Date: Sun, 24 Mar 2024 17:17:57 +0900 Subject: [PATCH] misc(zsh): run kubectl via command --- zsh/config.d/zshrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/zsh/config.d/zshrc b/zsh/config.d/zshrc index 8aa44495..eb8e0112 100644 --- a/zsh/config.d/zshrc +++ b/zsh/config.d/zshrc @@ -253,10 +253,10 @@ function current_architecture () { function current_context () { if command -v kubectl > /dev/null; then - kubectl config current-context &> /dev/null + command kubectl config current-context &> /dev/null kubectl_exit_code=$? if [ "$kubectl_exit_code" -eq 0 ]; then - echo "[%{$fg[blue]%}$(kubectl config current-context)%{${reset_color}%}] " + echo "[%{$fg[blue]%}$(command kubectl config current-context)%{${reset_color}%}] " else echo "" fi