Upgrade GitHub actions #10
Workflow file for this run
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
name: Pull Request | |
on: | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout PR | |
uses: actions/checkout@v4 | |
- name: Set up JDK 8 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '8' | |
distribution: 'zulu' | |
cache: maven | |
- name: Set up Maven | |
uses: stCarolas/[email protected] | |
with: | |
maven-version: "3.8.8" | |
# Override http://repo.gate.ac.uk to use https:// instead | |
- name: Configure Maven settings | |
uses: whelk-io/maven-settings-xml-action@v20 | |
with: | |
mirrors: > | |
[ | |
{ | |
"id": "gate.ac.uk-https", | |
"name": "GATE repo (secure)", | |
"mirrorOf": "gate.ac.uk", | |
"url": "https://repo.gate.ac.uk/content/groups/public/" | |
} | |
] | |
repositories: > | |
[ | |
{ | |
"id": "central", | |
"name": "Maven Central", | |
"url": "https://repo1.maven.org/maven2", | |
"releases": { | |
"enabled": "true" | |
}, | |
"snapshots": { | |
"enabled": "false" | |
} | |
} | |
] | |
plugin_repositories: > | |
[ | |
{ | |
"id": "central", | |
"name": "Maven Central", | |
"url": "https://repo1.maven.org/maven2", | |
"releases": { | |
"enabled": "true" | |
}, | |
"snapshots": { | |
"enabled": "false" | |
} | |
} | |
] | |
- name: Build with Maven | |
run: mvn --batch-mode -e clean install | |
- name: Upload Test Results | |
if: success() || failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Test Results | |
path: | | |
target/surefire-reports/*.xml | |
- name: Build site | |
run: mvn --batch-mode -e -DskipTests site | |
event_file: | |
name: "Event File" | |
runs-on: ubuntu-latest | |
steps: | |
- name: Upload | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Event File | |
path: ${{ github.event_path }} |