From e19da463b83ab7373b2e3b931c74002241c48b21 Mon Sep 17 00:00:00 2001 From: Marcelo Cyreno <812725+marcelocyreno@users.noreply.github.com> Date: Thu, 24 Aug 2023 12:38:34 -0300 Subject: [PATCH] fix: Remove unsupported '--short' flag from kubectl version command The '--short' flag was causing an error ("unknown flag: --short") when checking the kubectl client version. Tested on Client Version: v1.28.0 --- build/dev-env.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/dev-env.sh b/build/dev-env.sh index 3d21b7e15..500bf1be1 100755 --- a/build/dev-env.sh +++ b/build/dev-env.sh @@ -52,7 +52,7 @@ if [[ ${HELM_VERSION} -lt 3.10.0 ]]; then exit 1 fi -KUBE_CLIENT_VERSION=$(kubectl version --client --short 2>/dev/null | grep Client | awk '{print $3}' | cut -d. -f2) || true +KUBE_CLIENT_VERSION=$(kubectl version --client 2>/dev/null | grep Client | awk '{print $3}' | cut -d. -f2) || true if [[ ${KUBE_CLIENT_VERSION} -lt 24 ]]; then echo "Please update kubectl to 1.24.2 or higher" exit 1