Merge pull request #104 from marceldegraaf/dependabot/hex/sweet_xml-0… #304
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: Elixir CI | |
on: [push, pull_request] | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
unlock: [true, false] | |
elixir: [ "1.13", "1.14", "1.15", "1.16", "1.17", "1.18" ] | |
otp: [ 24, 25, 26, 27 ] | |
exclude: | |
- elixir: "1.13" | |
otp: 26 | |
- elixir: "1.13" | |
otp: 27 | |
- elixir: "1.14" | |
otp: 27 | |
- elixir: "1.15" | |
otp: 27 | |
- elixir: "1.16" | |
otp: 27 | |
- elixir: "1.17" | |
otp: 24 | |
- elixir: "1.18" | |
otp: 24 | |
name: OTP ${{matrix.otp}} / Elixir ${{matrix.elixir}} / ${{matrix.unlock}} | |
runs-on: ubuntu-latest | |
env: | |
MIX_ENV: test | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Elixir | |
uses: erlef/setup-beam@v1 | |
with: | |
elixir-version: ${{matrix.elixir}} | |
otp-version: ${{matrix.otp}} | |
- run: mix deps.unlock --all --check-unused | |
if: ${{ matrix.unlock }} | |
- run: mix deps.get --only test | |
- run: mix compile --warnings-as-errors | |
- run: mix test --warnings-as-errors | |
lint: | |
name: Run lint & format checks | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Elixir | |
uses: erlef/setup-beam@v1 | |
with: | |
elixir-version: '1.18' | |
otp-version: '27' | |
- name: Restore dependencies cache | |
uses: actions/cache@v4.2.0 | |
with: | |
path: deps | |
key: ${{ runner.os }}-mix-${{ hashFiles('**/mix.lock') }} | |
restore-keys: ${{ runner.os }}-mix- | |
- run: mix deps.get | |
- run: mix format --check-formatted |