From 53137110342edbdd0d879dc93a760f69ea0f22f6 Mon Sep 17 00:00:00 2001 From: Abhishek Ranjan Date: Mon, 3 Jun 2024 22:37:34 +0530 Subject: [PATCH] final fix --- scripts/install_protoc.sh | 7 +++---- scripts/vet-proto.sh | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/scripts/install_protoc.sh b/scripts/install_protoc.sh index e849dd400fe1..e7e1528cef6f 100755 --- a/scripts/install_protoc.sh +++ b/scripts/install_protoc.sh @@ -21,17 +21,16 @@ source "$(dirname $0)/vet-common.sh" PROTOC_VERSION="25.2" # Function to download pre-built binaries for Linux with -# ARCH as $1, OS as $2, and WORKDIR as $3 arguments. +# ARCH as $1, OS as $2, and INSTALL_PATH as $3 arguments. download_binary() { - # Check if protoc is already available + # Check if protoc is already available. if command -v protoc &> /dev/null; then if installed_version=$(protoc --version | cut -d' ' -f2 2>/dev/null); then if [ "$installed_version" = "$PROTOC_VERSION" ]; then echo "protoc version $PROTOC_VERSION is already installed." return else - echo "Existing protoc version ($installed_version) differs. Kindly make sure you have $PROTOC_VERSION installed." - exit 1 + die "Existing protoc version ($installed_version) differs. Kindly make sure you have $PROTOC_VERSION installed." fi else echo "Unable to determine installed protoc version. Starting the installation." diff --git a/scripts/vet-proto.sh b/scripts/vet-proto.sh index f3ecbd4b84ec..128267ea23a6 100755 --- a/scripts/vet-proto.sh +++ b/scripts/vet-proto.sh @@ -23,7 +23,7 @@ if [[ "$1" = "-install" ]]; then if [[ "${GITHUB_ACTIONS}" = "true" ]]; then source ./scripts/install_protoc.sh "/home/runner/go" else - die "run protoc installer https://github.com/grpc/grpc-go/scripts/install_protoc.sh." + die "run protoc installer https://github.com/grpc/grpc-go/scripts/install_protoc.sh" fi echo SUCCESS exit 0