Skip to content

Merge pull request #207 from xuwei-k/patch-3 #120

Merge pull request #207 from xuwei-k/patch-3

Merge pull request #207 from xuwei-k/patch-3 #120

Workflow file for this run

name: CI
on:
pull_request:
push:
jobs:
test:
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
java: 11
distribution: temurin
jobtype: 1
- os: ubuntu-latest
java: 11
distribution: temurin
jobtype: 2
- os: ubuntu-latest
java: 8
distribution: temurin
jobtype: 1
- os: windows-latest
java: 11
distribution: temurin
jobtype: 1
runs-on: ${{ matrix.os }}
env:
# define Java options for both official sbt and sbt-extras
JAVA_OPTS: -Xms2048M -Xmx2048M -Xss6M -XX:ReservedCodeCacheSize=256M -Dfile.encoding=UTF-8
JVM_OPTS: -Xms2048M -Xmx2048M -Xss6M -XX:ReservedCodeCacheSize=256M -Dfile.encoding=UTF-8
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup JDK
uses: actions/setup-java@v3
with:
distribution: "${{ matrix.distribution }}"
java-version: "${{ matrix.java }}"
cache: sbt
- name: Setup key
shell: bash
run: gpg --import test-key.gpg
- name: Build and test
if: ${{ matrix.jobtype == 1 }}
shell: bash
run: sbt -v clean +test +scripted
- name: Scalafmt
if: ${{ matrix.jobtype == 2 }}
shell: bash
run: sbt -v clean scalafmtSbtCheck +scalafmtCheckAll