diff --git a/.github/workflows/3.approve-snapshot.yml b/.github/workflows/3.approve-snapshot.yml index 2bbfbca0c..c9ff267c5 100644 --- a/.github/workflows/3.approve-snapshot.yml +++ b/.github/workflows/3.approve-snapshot.yml @@ -25,10 +25,11 @@ jobs: java-version: 18 - name: Define docker variables run: | - export version=$(mvn help:evaluate -Dexpression="project.version" -q -DforceStdout) - if [[ "$version" == *"SNAPSHOT"* ]]; then - echo "Dealing with a snapshot version. Current version: ${{ version }}" - echo "New version: ${ version //-SNAPSHOT//g }" + export VERSION=$(mvn help:evaluate -Dexpression="project.version" -q -DforceStdout) + echo "version=$VERSION" >> $GITHUB_ENV + if [[ "$env.version" == *"SNAPSHOT"* ]]; then + echo "Dealing with a snapshot version. Current version: ${{ env.version }}" + echo "New version: ${ env.version //-SNAPSHOT//g }" else - echo "Already released. Current version: ${ version }" + echo "Already released. Current version: ${ env.version }" fi \ No newline at end of file