Bump actions/checkout from 2.4.0 to 3
[reguloj.git] / .github / workflows / verify.yml
blob7a2de82266b342ee428739a1f47f3a044f8e30f1
1 name: Verify Commits
2 on:
3   pull_request:
4     branches: [ main ]
5   push:
6     branches: [ main ]
7     paths:
8       - ".github/workflows/*"
9       - "src/**"
10       - "pom.xml"
11 jobs:
12   build:
13     runs-on: ubuntu-latest
14     steps:
15       - uses: actions/checkout@v3
16       - name: Set up JDK 16
17         uses: actions/setup-java@v2
18         with:
19           java-version: 16
20           distribution: 'adopt'
21       - uses: actions/cache@v2.1.7
22         with:
23           path: ~/.m2/repository
24           key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
25           restore-keys: |
26             ${{ runner.os }}-maven-
27       - id: gpg
28         name: GPG Key
29         run: echo "${{ secrets.GPG_SECRET_KEY_BASE64 }}" | base64 --decode > $GITHUB_WORKSPACE/signing.key.asc
30       - id: maven
31         name: Build with Maven
32         run: mvn --batch-mode verify -Dpgp.secretkey=keyfile:$GITHUB_WORKSPACE/signing.key.asc -Dpgp.passphrase=literal:${{ secrets.GPG_SECRET_KEY_PASSWORD }}