diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 54f8f3e38f..20cc2de82f 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -5,25 +5,29 @@ name: Java CI with Maven on: push: - branches: [ "main" ] + branches: ["main"] pull_request: - branches: [ "main" ] + branches: ["main"] + +permissions: + contents: read jobs: build: strategy: matrix: - java-version: [ 11, 17 ] - runs-on: [ ubuntu-latest ] + java-version: [11, 17] + runs-on: [ubuntu-latest] name: Jdk ${{ matrix.java-version }}, os ${{ matrix.runs-on }} runs-on: ${{ matrix.runs-on }} steps: - - uses: actions/checkout@v3 - - name: Set up JDK ${{ matrix.java-version }} - uses: actions/setup-java@v3 - with: - java-version: ${{ matrix.java-version }} - distribution: 'temurin' - cache: maven - - name: Build and run tests with Maven - run: mvn --batch-mode --update-snapshots verify + - uses: actions/checkout@v3 + - name: Set up JDK ${{ matrix.java-version }} + uses: actions/setup-java@v3 + with: + java-version: ${{ matrix.java-version }} + distribution: "temurin" + cache: maven + persist-credentials: false + - name: Build and run tests with Maven + run: mvn --batch-mode --update-snapshots verify