forked from boskworks/bosk
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (32 loc) · 1.15 KB
/
build-and-test.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
# Based on:
# - https://github.com/assertj/assertj/blob/f08f94806675ccaaa347e4cbc56cf02efa8cd3be/.github/workflows/release.yml#L1
# - https://github.com/testcontainers/testcontainers-java/blob/de20484e53eb8d1f580b74ff9df31261b596ab5c/.github/workflows/release.yml#L1
name: "Build and test"
on:
push:
branches:
- '**'
tags-ignore: # already run when a commit is pushed; no need to also run when it's tagged
- '**'
jobs:
build_and_test:
name: Build and test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Maven Central
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: temurin
- name: Run Gradle Test
run: |
./gradlew spotlessCheck spotBugsMain test \
--no-daemon -i --fail-fast
env:
ORG_GRADLE_PROJECT_ossrhUsername: ${{secrets.OSSRH_USERNAME}}
ORG_GRADLE_PROJECT_ossrhPassword: ${{secrets.OSSRH_TOKEN}}
ORG_GRADLE_PROJECT_signingKey: ${{secrets.GPG_PRIVATE_KEY}}
ORG_GRADLE_PROJECT_signingPassword: ${{secrets.GPG_PASSWORD}}