Skip to content

Add CI

Add CI #1

Workflow file for this run

name: CI
on:
push:
branches:
- "**"
tags-ignore:
- "**"
jobs:
continuous-integration:
runs-on: ubuntu-latest
env:
MAVEN_CLI_OPTS: "--batch-mode --errors --fail-at-end --show-version"
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '21'
cache: 'maven'
- name: Cache
uses: actions/cache@v4
with:
path: .m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-maven-
- name: Test
run: mvn $MAVEN_CLI_OPTS test
- name: Build lib
run: mvn -$MAVEN_CLI_OPTS clean package -DskipTests
- name: Build CLI
run: mvn $MAVEN_CLI_OPTS clean package -Pcli -DskipTests