Skip to content

WIP: Upgrade CI

WIP: Upgrade CI #84

Workflow file for this run

name: CI
on: push
jobs:
unit-test:
runs-on: ubuntu-latest
name: OTP ${{matrix.otp}} / Elixir ${{matrix.elixir}}
env:
MIX_ENV: test
strategy:
fail-fast: false
matrix:
include:
- elixir: 1.15.6
otp: 25.3.2.6
lint: lint
- elixir: 1.15.6
otp: 24.3.4.13
- elixir: 1.11.4
otp: 21.3.8.24
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Elixir and Erlang
uses: erlef/setup-beam@v1
with:
elixir-version: ${{ matrix.elixir }}
otp-version: ${{ matrix.otp }}
- name: Restore deps and _build cache
uses: actions/cache@v3
with:
path: |
deps
_build
key: ${{ runner.os }}-${{ matrix.elixir }}-${{ matrix.otp }}-${{ hashFiles('**/mix.lock') }}
restore-keys: |
${{ runner.os }}-${{ matrix.elixir }}-${{ matrix.otp }}-
- name: Install dependencies
run: mix deps.get
- name: Compile deps
run: mix deps.compile
- name: Check unused dependencies
run: mix deps.unlock --check-unused
if: ${{ matrix.lint }}
- name: Compile lint
run: mix compile --warning-as-errors
if: ${{ matrix.lint }}
- name: Run tests
run: mix test
- name: Check format
run: mix format --check-formatted
- name: Check quality
run: mix credo --all --strict || true