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

slachiewicz pushed a commit to branch MJLINK-56_junit5
in repository https://gitbox.apache.org/repos/asf/maven-jlink-plugin.git

commit a2a85bc00e4922ce78b9473f6eaa69f6cc605137
Author: Benjamin Marwell <bmarw...@apache.org>
AuthorDate: Wed Nov 18 10:31:34 2020 +0100

    jdk8 with buildchain
    
    Closes #18
---
 .github/workflows/maven.yml | 33 +++++++++++++++++++++++++++++++++
 .gitignore                  |  2 ++
 2 files changed, 35 insertions(+)

diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml
index cf4a2fa..3f38cf9 100644
--- a/.github/workflows/maven.yml
+++ b/.github/workflows/maven.yml
@@ -42,10 +42,43 @@ jobs:
           restore-keys: |
             maven-${{ matrix.os }}-java${{ matrix.java }}-
             maven-${{ matrix.os }}-
+      - name: Set up Toolchain
+        if: ${{ matrix.java == '8' && matrix.os == 'ubuntu-latest' }}
+        uses: DamianReeves/write-file-action@v1.0
+        with:
+          path: it-toolchains.xml
+          contents: |
+            <?xml version="1.0" encoding="UTF8"?>
+            <toolchains>
+              <toolchain>
+                <type>jdk</type>
+                  <provides>
+                    <version>11</version>
+                    <vendor>adopt</vendor>
+                  </provides>
+                  <configuration>
+                    <jdkHome>$HOME/.jabba/jdk/adopt-openj9@1.11.0-7</jdkHome>
+                  </configuration>
+              </toolchain>
+            </toolchains>
+          write-mode: overwrite
+      - name: Install Toolchain JDK
+        if: ${{ matrix.java == '8' && matrix.os == 'ubuntu-latest' }}
+        uses: battila7/jdk-via-jabba@v1
+        with:
+          jdk: adopt-openj9@1.11.0-7
+      - name: delete jdk-via-jabba tmp dir
+        if: ${{ matrix.java == '8' && matrix.os == 'ubuntu-latest' }}
+        run: rm -rvf _temp/
       - name: Set up JDK
         uses: actions/setup-java@v1
         with:
           java-version: ${{ matrix.java }}
 
       - name: Build with Maven
+        if: ${{ matrix.java != '8' || matrix.os != 'ubuntu-latest' }}
         run: mvn verify -e -B -V -Prun-its
+      - name: Build with Maven and Toolchain
+        if: ${{ matrix.java == '8' && matrix.os == 'ubuntu-latest' }}
+        run: mvn verify -e -B -V -Prun-its --global-toolchains 
it-toolchains.xml
+
diff --git a/.gitignore b/.gitignore
index f79c928..4b8cf07 100644
--- a/.gitignore
+++ b/.gitignore
@@ -13,3 +13,5 @@ out/
 /bootstrap
 /dependencies.xml
 .java-version
+# for testing
+it-toolchains.xml

Reply via email to