From 7a4198c7369276a1a1a38efcf93b44b66301673d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcin=20Wo=C5=BAniak?= Date: Sat, 28 Dec 2024 23:03:04 +0100 Subject: [PATCH] Changed a `KUBECTL_LOCATION` --- .local/bin/Update-pkg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.local/bin/Update-pkg b/.local/bin/Update-pkg index 09e92b7..2e4374a 100755 --- a/.local/bin/Update-pkg +++ b/.local/bin/Update-pkg @@ -355,9 +355,9 @@ function install_kubernetes() { LINK="" CURRENT_VERSION="" REMOTE_VERSION=$(curl -L -s https://dl.k8s.io/release/stable.txt) - KUBECTL_LOCATION="$HOME/.local/bin/kubectl" + KUBECTL_LOCATION="/opt/homebrew/bin/kubectl" - [ -f $HOME/.local/bin/kubectl ] && CURRENT_VERSION=$($KUBECTL_LOCATION version --client | grep --color=no -iEo 'Client Version: v[0-9\.]+' | grep -ioE --color=no 'v[0-9\.]+') + [ -f $KUBECTL_LOCATION ] && CURRENT_VERSION=$($KUBECTL_LOCATION version --client | grep --color=no -iEo 'Client Version: v[0-9\.]+' | grep -ioE --color=no 'v[0-9\.]+') if [ "$REMOTE_VERSION" == "$CURRENT_VERSION" ]; then timestamp "The current version of the kubectl is the same as the newest version"