-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (45 loc) · 1.25 KB
/
maven-swag-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
50
51
52
53
54
name: Maven Build Artifact
on:
workflow_call:
inputs:
node-version:
description: 'Node version'
required: false
default: "16"
type: string
java-version:
description: 'Java version'
required: false
default: "17"
type: string
java-distribution:
description: 'Java distribution'
required: false
default: "temurin"
type: string
jobs:
bundle:
runs-on: ubuntu-20.04
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Maven
uses: actions/setup-java@v4
with:
java-version: ${{ inputs.java-version }}
distribution: ${{ inputs.java-distribution }}
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ inputs.node-version }}
cache: npm
- name: NPM install
run: npm install
- name: Bundle specification
run: npm run build
- name: Validate specification
run: npm run validate
- name: Build server jar
run: mvn --batch-mode clean package -f pom.xml -P="server"
- name: Build client jar
run: mvn --batch-mode clean package -f pom.xml -P="client"