You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by sj...@apache.org on 2022/11/15 23:07:49 UTC

[maven-integration-testing] branch master updated: Update actions in GH build

This is an automated email from the ASF dual-hosted git repository.

sjaranowski pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-integration-testing.git


The following commit(s) were added to refs/heads/master by this push:
     new 41104b14e Update actions in GH build
41104b14e is described below

commit 41104b14e215d74c3024e3cfb026f62d4aa27a1e
Author: Slawomir Jaranowski <s....@gmail.com>
AuthorDate: Sat Nov 12 17:38:44 2022 +0100

    Update actions in GH build
    
    Old actions use deprecated node 12
    
    - checkout v2 -> v3
    - setup-java v2 -> v3
    - disable access to GITHUB_TOKEN
    - don't store credentials with checkout
---
 .github/workflows/maven-verify.yml | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/.github/workflows/maven-verify.yml b/.github/workflows/maven-verify.yml
index 4548530a6..1159bc232 100644
--- a/.github/workflows/maven-verify.yml
+++ b/.github/workflows/maven-verify.yml
@@ -19,8 +19,15 @@ name: Java CI
 
 on: [push, pull_request]
 
+# clear all permissions for GITHUB_TOKEN
+permissions: {}
+
 jobs:
   build:
+
+    # execute on any push or pull request from forked repo
+    if: github.event_name == 'push' || ( github.event_name == 'pull_request' && github.event.pull_request.head.repo.fork )
+
     strategy:
       matrix:
         os: [ubuntu-latest]
@@ -30,10 +37,12 @@ jobs:
     runs-on: ${{ matrix.os }}
 
     steps:
-      - uses: actions/checkout@v2
+      - uses: actions/checkout@v3
+        with:
+          persist-credentials: false
 
       - name: Set up JDK
-        uses: actions/setup-java@v2
+        uses: actions/setup-java@v3
         with:
           java-version: ${{ matrix.java }}
           distribution: 'temurin'
@@ -43,6 +52,4 @@ jobs:
         run: mvn --errors --batch-mode --show-version wrapper:wrapper "-Dmaven=3.8.6"
 
       - name: Running integration tests
-        # execute on any push or pull request from forked repo
-        if: github.event_name == 'push' || ( github.event_name == 'pull_request' && github.event.pull_request.head.repo.fork )
         run: "./mvnw -B clean install -Prun-its,embedded -Dmaven.repo.local=`pwd`/repo"