diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 375169d..17aee22 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -38,18 +38,21 @@ jobs: - name: Set Release version env variable run: | mvn versions:set -DremoveSnapshot -DgenerateBackupPoms=false + + - name: Set Release version env variable + run: | echo "RELEASE_VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)" >> $GITHUB_ENV IFS='.' read -ra VER <<< "${{ env.RELEASE_VERSION }}" MAJOR=${VER[0]} MINOR=${VER[1]} let "PREV_MINOR=MINOR-1" - RELEASE_VERSION="${MAJOR}.${PREV_MINOR}" - echo "PREV_VERSION=$PREV_VERSION" >> $GITHUB_ENV + PREV_VERSION="${MAJOR}.${PREV_MINOR}" + echo "RELEASE_VERSION=$PREV_VERSION" >> $GITHUB_ENV - name: Criando executavel run: | mvn versions:set -DnewVersion=${{ env.RELEASE_VERSION }} - mvn -B assembly:single --file pom.xml + mvn mvn clean compile assembly:single --file pom.xml - name: Criando pasta para External Jar run: | diff --git a/pom.xml b/pom.xml index 1d4a122..697526e 100644 --- a/pom.xml +++ b/pom.xml @@ -74,6 +74,7 @@ + ${project.artifactId}-${project.version} org.apache.maven.plugins