-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (37 loc) · 1.38 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# GitHub Actions Workflow created for testing the application
name: Build
on:
workflow_dispatch:
push:
permissions:
pull-requests: write
jobs:
runTests:
runs-on: ubuntu-latest
steps:
# Check out current repository
- name: checkout
uses: actions/checkout@v4
# Setup Java environment for the next steps
- name: Setup Java
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'corretto'
# Setup any environment variable in this step
- name: Setup environment
run: |
echo "MVN_OPTS=-Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=WARN -Dorg.slf4j.simpleLogger.showDateTime=true -Djava.awt.headless=true --batch-mode --fail-at-end --show-version -DinstallAtEnd=true -DdeployAtEnd=true" >> $GITHUB_ENV
# Run tests and build the application
- name: build
working-directory: './'
run: |
./mvnw verify -DskipTests=false -Dmaven.test.skip=false
- name: AutoMerge Dependabot PRs
if: success() && github.actor == 'dependabot[bot]' && github.ref != 'refs/heads/main'
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
GH_TOKEN: ${{secrets.CLASSIC_GH_TOKEN}}
run: |
echo "found successful dependabot PR, merging it"
gh pr merge --merge --admin