From caefa20110977d562e90bfddcd5fd613f74f99df Mon Sep 17 00:00:00 2001 From: Ricardo Carneiro Date: Mon, 22 Sep 2025 09:22:50 -0300 Subject: [PATCH] =?UTF-8?q?fix:=20build=20de=20release=20com=20arquivo=20n?= =?UTF-8?q?=C3=A3o=20encontrado?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/deploy-bcards.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/deploy-bcards.yml b/.gitea/workflows/deploy-bcards.yml index 77542da..8ba6b7e 100644 --- a/.gitea/workflows/deploy-bcards.yml +++ b/.gitea/workflows/deploy-bcards.yml @@ -118,7 +118,8 @@ jobs: elif [[ "$BRANCH_NAME" == Release/* ]]; then # Release = Swarm tests (Orange Pi arm64) - usando Dockerfile simples também VERSION_RAW=${BRANCH_NAME#Release/} - VERSION=$(echo "$VERSION_RAW" | sed 's/^[Vv]//') + # Only remove V/v if it's at the start and followed by a number (like v1.0.0) + VERSION=$(echo "$VERSION_RAW" | sed 's/^[Vv]\([0-9]\)/\1/') [ -z "$VERSION" ] && VERSION="0.0.1" echo "tag=$VERSION" >> $GITHUB_OUTPUT @@ -544,12 +545,16 @@ jobs: if: startsWith(github.ref_name, 'Release/') steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Extract version id: version run: | BRANCH_NAME="${{ github.ref_name }}" VERSION_RAW=${BRANCH_NAME#Release/} - VERSION=$(echo "$VERSION_RAW" | sed 's/^[Vv]//') + # Only remove V/v if it's at the start and followed by a number (like v1.0.0) + VERSION=$(echo "$VERSION_RAW" | sed 's/^[Vv]\([0-9]\)/\1/') [ -z "$VERSION" ] && VERSION="0.0.1" echo "version=$VERSION" >> $GITHUB_OUTPUT echo "📦 Deploying version: $VERSION"