forked from agouge/Java-Network-Analyzer
-
Notifications
You must be signed in to change notification settings - Fork 9
49 lines (43 loc) · 1.3 KB
/
CI 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
44
45
46
47
48
49
name: CI build
on:
pull_request:
branches: [ master ]
workflow_run:
workflows: ["CI release"]
branches: [ master ]
types:
- completed
workflow_dispatch:
jobs:
build:
# Main build job used to
name: Build
runs-on: ubuntu-latest
steps:
# Checkout the source code of the project
- name: Checkout
uses: actions/checkout@v2
# Setup the jdk using version 11 of adoptOpenJDK
- name: Setup java 11 using adoptOpenJDK
uses: actions/setup-java@v2
with:
distribution: adopt
java-version: 11
# Build the project using
# - clean : clean up the workspace
# - validate : perform different check like the dependency and plugin version update
# - compile : compile the source code.
# - test : Perform the tests.
- name: Build
run: mvn -ntp clean validate compile test javadoc:test-javadoc
# Check changelog update
- name: Check changelog update
uses: dorny/paths-filter@v2
id: changes
with:
filters: |
changelog:
- 'docs/CHANGELOG.md'
if: github.event_name != 'workflow_dispatch'
- if: steps.changes.outputs.changelog == 'false' && github.event_name != 'workflow_dispatch'
run: exit 1