-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
upgrade github actions, add setup-gradle action
- Loading branch information
Showing
1 changed file
with
20 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,39 +39,49 @@ jobs: | |
- name: Set GraalVM platform for ubuntu-latest | ||
if: ${{ matrix.platform == 'ubuntu-latest' }} | ||
run: echo "GRAALVM_PLATFORM=linux-amd64" >> $GITHUB_ENV | ||
|
||
- name: Set GraalVM platform for windows-latest | ||
if: ${{ matrix.platform == 'windows-latest' }} | ||
run: echo "GRAALVM_PLATFORM=windows-amd64" >> $env:GITHUB_ENV | ||
|
||
- uses: actions/checkout@v3 | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up JDK ${{ matrix.jdk }} | ||
uses: actions/setup-java@v3 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '${{ matrix.jdk }}' | ||
distribution: 'oracle' | ||
cache: 'gradle' | ||
|
||
# headless X11 setup according to | ||
# https://stackoverflow.com/questions/68292797/running-java-gui-tests-on-github-using-xvfb | ||
- name: Set up virtual X11 | ||
if: ${{ matrix.platform == 'ubuntu-latest' }} | ||
run: sudo apt-get -y install xvfb | ||
|
||
- name: Start virtual frame buffer | ||
if: ${{ matrix.platform == 'ubuntu-latest' }} | ||
run: Xvfb :19 -screen 0 1024x768x16 & | ||
- name: Build with Gradle | ||
uses: gradle/[email protected] | ||
env: | ||
DISPLAY: ":19" | ||
OSM_DEV_API_PASSWORD: "${{ secrets.OSM_DEV_API_PASSWORD }}" | ||
|
||
- name: Setup Gradle | ||
uses: gradle/actions/setup-gradle@v4 | ||
with: | ||
arguments: | | ||
build | ||
gradle-version: "8.12" | ||
|
||
- name: Build with Gradle | ||
run: | | ||
./gradlew build | ||
-Pplugin.josmCompileVersion=${{ matrix.josm-version}} | ||
-Pgraalvm.jdk=jdk${{ matrix.jdk }} | ||
-Pgraalvm.platform=${{ env.GRAALVM_PLATFORM }} | ||
env: | ||
DISPLAY: ":19" | ||
OSM_DEV_API_PASSWORD: "${{ secrets.OSM_DEV_API_PASSWORD }}" | ||
|
||
- name: Store reports | ||
if: failure() | ||
uses: actions/upload-artifact@v3 | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: reports | ||
path: | | ||
|