Skip to content

Update CI and compatibility #10

Update CI and compatibility

Update CI and compatibility #10

Workflow file for this run

on: [push, pull_request]
jobs:
lint:
runs-on: ubuntu-latest
name: Lint (OTP ${{matrix.otp}} / Elixir ${{matrix.elixir}})
strategy:
matrix:
otp: ['26']
elixir: ['1.16']
steps:
- uses: actions/checkout@v3
- name: BEAM setup
id: beam
uses: erlef/setup-beam@v1
with:
otp-version: ${{matrix.otp}}
elixir-version: ${{matrix.elixir}}
- name: Build cache
uses: actions/cache@v3
with:
key: |
${{ runner.os }}-${{ steps.beam.outputs.elixir-version }}-${{ steps.beam.outputs.otp-version }}-build
restore-keys: |
${{ runner.os }}-${{ steps.beam.outputs.elixir-version }}-${{ steps.beam.outputs.otp-version }}-build
path: |
_build
- name: PLT cache
uses: actions/cache@v3
id: plt_cache
with:
key: |
${{ runner.os }}-${{ steps.beam.outputs.elixir-version }}-${{ steps.beam.outputs.otp-version }}-plt
restore-keys: |
${{ runner.os }}-${{ steps.beam.outputs.elixir-version }}-${{ steps.beam.outputs.otp-version }}-plt
path: |
priv/plts
- run: mix deps.get
- run: mix deps.unlock --check-unused
- run: mix compile --warnings-as-errors
- run: mix format --check-formatted
- run: mix credo --strict --all
- run: mix dialyzer
test:
runs-on: ubuntu-20.04
name: Test (OTP ${{matrix.otp}} / Elixir ${{matrix.elixir}})
strategy:
matrix:
elixir: ["1.16", "1.15", "1.14", "1.13", "1.12"]
otp: ["26", "25", "24", "23", "22"]
exclude:
- { otp: "23", elixir: "1.16" }
- { otp: "22", elixir: "1.16" }
- { otp: "23", elixir: "1.15" }
- { otp: "22", elixir: "1.15" }
- { otp: "26", elixir: "1.14" }
- { otp: "22", elixir: "1.14" }
- { otp: "26", elixir: "1.13" }
- { otp: "25", elixir: "1.13" }
- { otp: "26", elixir: "1.12" }
- { otp: "25", elixir: "1.12" }
steps:
- uses: actions/checkout@v3
- name: BEAM setup
id: beam
uses: erlef/setup-beam@v1
with:
otp-version: ${{matrix.otp}}
elixir-version: ${{matrix.elixir}}
- name: Mix cache
uses: actions/cache@v3
with:
key: |
${{ runner.os }}-${{ steps.beam.outputs.elixir-version }}-${{ steps.beam.outputs.otp-version }}-mix
restore-keys: |
${{ runner.os }}-${{ steps.beam.outputs.elixir-version }}-${{ steps.beam.outputs.otp-version }}-mix
path: |
~/.mix
- name: Build cache
uses: actions/cache@v3
with:
key: |
${{ runner.os }}-${{ steps.beam.outputs.elixir-version }}-${{ steps.beam.outputs.otp-version }}-build
restore-keys: |
${{ runner.os }}-${{ steps.beam.outputs.elixir-version }}-${{ steps.beam.outputs.otp-version }}-build
path: |
_build
- run: mix deps.get
- run: mix test