diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d9821ae6..32042a1a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -32,11 +32,6 @@ jobs: with: distribution: 'temurin' java-version: 21 - - name: Cache Maven Packages - uses: actions/cache@v4 - with: - path: ~/.m2 - key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} - restore-keys: ${{ runner.os }}-m2- + cache: 'maven' - name: Build with Maven run: mvn -B --no-transfer-progress package --file pom.xml -Dsurefire.skipAfterFailureCount=1 diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 0e4ef44a..ffe2725a 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -44,6 +44,7 @@ jobs: with: distribution: 'temurin' java-version: 21 + cache: 'maven' # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index cdab0111..f1d3f999 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -21,6 +21,7 @@ jobs: with: distribution: 'temurin' java-version: 21 + cache: 'maven' - name: Set env for master(latest) release if: github.ref_name == 'master' @@ -32,13 +33,6 @@ jobs: run: | echo "RELEASE_NAME=${{ github.ref_name }}" >> $GITHUB_ENV - - name: Cache Maven Packages - uses: actions/cache@v4 - with: - path: ~/.m2 - key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} - restore-keys: ${{ runner.os }}-m2- - - name: Build project run: mvn -B --no-transfer-progress package -Passembly --file pom.xml -Drevision=${{ env.RELEASE_NAME }}