Skip to content

Commit e87931e

Browse files
committed
Specify maven workflow
1 parent d9b5a28 commit e87931e

File tree

1 file changed

+18
-3
lines changed

1 file changed

+18
-3
lines changed

.github/workflows/maven-multi-os.yml

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,23 @@ jobs:
2020
distribution: 'temurin'
2121
java-version: '21'
2222
- name: Compile with Maven
23-
run: mvn clean compile
23+
run: |
24+
if [[ "${{ runner.os }}" == "Linux" ]]; then
25+
mvn clean compile -Dos.version=linux-x86_64
26+
elif [[ "${{ runner.os }}" == "macOS" ]]; then
27+
mvn clean compile -Dos.version=macosx-x86_64
28+
fi
2429
- name: Validate Maven Project
25-
run: mvn validate
30+
run: |
31+
if [[ "${{ runner.os }}" == "Linux" ]]; then
32+
mvn validate -Dos.version=linux-x86_64
33+
elif [[ "${{ runner.os }}" == "macOS" ]]; then
34+
mvn validate -Dos.version=macosx-x86_64
35+
fi
2636
- name: Package with Maven (Fat JAR)
27-
run: mvn clean package
37+
run: |
38+
if [[ "${{ runner.os }}" == "Linux" ]]; then
39+
mvn clean package -Dos.version=linux-x86_64
40+
elif [[ "${{ runner.os }}" == "macOS" ]]; then
41+
mvn clean package -Dos.version=macosx-x86_64
42+
fi

0 commit comments

Comments
 (0)