-
Notifications
You must be signed in to change notification settings - Fork 17
32 lines (32 loc) · 965 Bytes
/
ci.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
name: CI jobs
on:
push:
branches:
- main
- r[0-9]+.*
pull_request:
branches:
- main
- r[0-9]+.*
types: [opened, reopened, synchronize]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Configure Java
uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '11'
- name: Checkout repository
uses: actions/checkout@v1
- name: Build project
run: |
java -version
mvn -version
mvn clean install -B -U -e
- name: Deploy snapshot artifacts
if: github.event_name == 'push' && contains(github.ref, 'main')
run: |
echo "<settings><servers><server><id>ossrh</id><username>${{ secrets.CI_DEPLOY_USERNAME }}</username><password>${{ secrets.CI_DEPLOY_PASSWORD }}</password></server></servers></settings>" > $HOME/.m2/settings.xml
mvn deploy -B -U -e -Dmaven.test.skip=true