From 039fbd3e6264298d9f195557f46b5893c2f1375a Mon Sep 17 00:00:00 2001 From: m-wayne Date: Mon, 8 Jul 2024 13:32:45 -0700 Subject: [PATCH] set jdk (17) in ci workflow. update actions --- .github/workflows/on-push.yml | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/.github/workflows/on-push.yml b/.github/workflows/on-push.yml index 084f4b2..823d5b4 100644 --- a/.github/workflows/on-push.yml +++ b/.github/workflows/on-push.yml @@ -31,11 +31,11 @@ jobs: steps: # Clone the repo - name: Clone Repo - uses: actions/checkout@v2 + uses: actions/checkout@v4 # Cache the gradle build dependencies for faster builds - name: Cache Gradle Dependencies - uses: actions/cache@v2 + uses: actions/cache@v4 with: path: ${{ env.GRADLE_CACHE_PATH }} key: ${{ runner.os }}-${{ hashFiles('.gradle-cache-buster') }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', '**/gradle.properties') }} @@ -48,7 +48,7 @@ jobs: # Upload the html test report as a build artifact for easier debugging - name: Upload Test Report if: ${{ always() }} - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: name: ${{ matrix.test-group }} Test Reports path: ${{ matrix.base-folder }}/build/reports/tests/${{ matrix.test-report-folder }}/* @@ -56,7 +56,7 @@ jobs: # Upload XML logs as build artifacts (accessible from the Summary page of the run) - name: Upload JUnit Logs if: ${{ always() }} - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: name: ${{ matrix.test-group }} Testing Logs path: "${{ matrix.base-folder }}/build/test-results/test*UnitTest/TEST-*.xml" @@ -82,16 +82,23 @@ jobs: steps: # Retrieve the repo - name: Clone Repo - uses: actions/checkout@v2 + uses: actions/checkout@v4 # Cache the gradle build dependencies for faster builds - name: Cache Gradle Dependencies - uses: actions/cache@v2 + uses: actions/cache@v4 with: path: ${{ env.GRADLE_CACHE_PATH }} key: ${{ runner.os }}-${{ hashFiles('.gradle-cache-buster') }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', '**/gradle.properties') }} restore-keys: ${{ runner.os }}-${{ hashFiles('.gradle-cache-buster') }}-gradle- + # Download Java and set version + - name: Set Up JDK + uses: actions/setup-java@v4 + with: + java-version: ${{ vars.JDK_VERSION }} + distribution: 'temurin' + # Build using gradle - name: Build ${{ matrix.project }} Release run: ./gradlew ${{ matrix.gradle-arguments }} @@ -116,7 +123,7 @@ jobs: # Upload the AAR file as a build artifact (accessible from the Summary page of the run) - name: Upload AAR file - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: name: ${{ matrix.artifact-name }} path: ${{ matrix.artifact-path }}