You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
40 lines
908 B
40 lines
908 B
name: Build and Test
|
|
|
|
on:
|
|
pull_request:
|
|
branches:
|
|
- master
|
|
- main
|
|
push:
|
|
branches:
|
|
- master
|
|
- main
|
|
|
|
jobs:
|
|
verify:
|
|
name: Maven verify (JDK 17)
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up JDK 17
|
|
uses: actions/setup-java@v4
|
|
with:
|
|
distribution: temurin
|
|
java-version: "17"
|
|
cache: maven
|
|
|
|
- name: Check Java source BOM
|
|
shell: bash
|
|
run: |
|
|
python3 - <<'PY'
|
|
from pathlib import Path
|
|
files = [path for path in Path('.').rglob('*.java')
|
|
if path.read_bytes().startswith(b'\xef\xbb\xbf')]
|
|
if files:
|
|
raise SystemExit('UTF-8 BOM found:\n' + '\n'.join(map(str, files)))
|
|
PY
|
|
|
|
- name: Build and run existing tests
|
|
run: mvn -B -s settings.xml verify
|
|
|