-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (52 loc) · 1.7 KB
/
Release-Please.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
on:
workflow_dispatch:
push:
branches:
- 'main'
# https://github.com/OWNER/REPO/settings/actions
# MUST CHANGE GITHUB_TOKEN PERMISSION FROM READ TO WRITE
# MUST CHANGE GITHUB_TOKEN PERMISSION ALLOW PULL REQUESTS
# ⚠ ⚠ ⚠ You need merge pull request manually ⚠ ⚠ ⚠
permissions:
contents: write
pull-requests: write
jobs:
build-and-test:
strategy:
matrix:
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
services:
postgres:
image: postgres:13
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: postgres
ports:
- 5432:5432
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Prepare database
run: PGPASSWORD=postgres psql -h localhost -U postgres -p 5432 -f './src/test/resources/TEST.sql'
- name: Install JDK
uses: actions/setup-java@v3
with:
java-version: 17
distribution: 'adopt'
cache: 'maven'
- name: Run tests
run: mvn test
release-please:
needs: build-and-test
strategy:
matrix:
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: google-github-actions/release-please-action@v3
with:
release-type: maven
#package-name: release-please-action