From b9485978333a2d04b3f6c5722ad576bfbf714882 Mon Sep 17 00:00:00 2001 From: Guilherme Martin Date: Sun, 18 Feb 2024 00:55:34 -0300 Subject: [PATCH] Update dotnet.yml --- .github/workflows/dotnet.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index 24a364d..f5344ce 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -40,6 +40,10 @@ jobs: IFS='.' read -r -a version_parts <<< "$latest_version" echo "Version parts array: ${version_parts[@]}" + if [ "${#version_parts[@]}" -lt 3 ]; then + echo "Error: Insufficient version parts." + exit 1 + fi ((version_parts[2]++)) echo "Incremented version parts array: ${version_parts[@]}" new_version="${version_parts[0]}.${version_parts[1]}.${version_parts[2]}"