Merge pull request #114 from betarixm/feat/test-docker #183
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- "**" | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: temurin | |
java-version: 20 | |
cache: sbt | |
- name: Run tests | |
run: sbt -v "test; e2e / test" | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: temurin | |
java-version: 20 | |
cache: sbt | |
- name: Run scalafix | |
run: sbt -v "scalafixAll --check" | |
- name: Run scalafmt | |
run: sbt -v "scalafmtCheck" | |
- uses: DavidAnson/markdownlint-cli2-action@v13 | |
with: | |
globs: "**/*.md" | |
build: | |
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: temurin | |
java-version: 20 | |
cache: sbt | |
- run: sbt assembly | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: master | |
path: build/master | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: worker | |
path: build/worker | |
- name: Release development build | |
if: github.ref == 'refs/heads/develop' | |
uses: marvinpinto/action-automatic-releases@latest | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
automatic_release_tag: "latest" | |
prerelease: true | |
title: "Development Build" | |
files: | | |
build/master | |
build/worker | |
- name: Release production build | |
if: github.ref == 'refs/heads/main' | |
uses: marvinpinto/action-automatic-releases@latest | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
automatic_release_tag: "latest" | |
title: "Production Build" | |
files: | | |
build/master | |
build/worker |