update workflows
[reguloj.git] / .github / workflows / verify.yml
blob54512d7626d5c3f25016a77c068bdc7429feb07f
1 name: Verify Commits
2 on:
3   pull_request:
4     branches: [ main ]
5   push:
6     branches: [ main ]
7     paths:
8       - .github/workflows/verify.yml
9       - src/**
10       - pom.xml
11 env:
12   JAVA_VERSION: 17
13   JAVA_PACKAGE: jdk
14   JAVA_ARCH: x64
15   JAVA_DISTRO: temurin
16 jobs:
17   build:
18     runs-on: ubuntu-latest
19     steps:
20       - uses: actions/checkout@v3
21       - name: Set up Java
22         uses: actions/setup-java@v3
23         with:
24           java-version: ${{ env.JAVA_VERSION }}
25           java-package: ${{ env.JAVA_PACKAGE }}
26           architecture: ${{ env.JAVA_ARCH }}
27           distribution: ${{ env.JAVA_DISTRO }}
28       - uses: actions/cache@v3
29         with:
30           path: ~/.m2/repository
31           key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
32           restore-keys: |
33             ${{ runner.os }}-maven-
34       - id: maven
35         name: Build with Maven
36         run: mvn --batch-mode verify