Relax circuits_i2c dependency to allow v2.0 #74
Workflow file for this run
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, pull_request] | |
jobs: | |
deps: | |
name: Dependencies | |
runs-on: ubuntu-20.04 | |
env: | |
MIX_ENV: test | |
strategy: | |
matrix: | |
include: | |
- elixir: 1.13 | |
otp: 24 | |
- elixir: 1.14 | |
otp: 25 | |
steps: | |
- name: Cancel Previous Runs | |
uses: styfle/[email protected] | |
with: | |
access_token: ${{ github.token }} | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Setup | |
uses: erlef/setup-beam@v1 | |
with: | |
elixir-version: ${{ matrix.elixir }} | |
otp-version: ${{ matrix.otp }} | |
- name: Retrieve Cached Dependencies | |
uses: actions/cache@v3 | |
id: mix-cache | |
with: | |
path: | | |
deps | |
_build | |
priv/plts | |
key: ${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('mix.lock') }} | |
- name: Install Dependencies | |
if: steps.mix-cache.outputs.cache-hit != 'true' | |
run: | | |
mkdir -p priv/plts | |
mix local.rebar --force | |
mix local.hex --force | |
mix deps.get | |
mix deps.compile | |
mix dialyzer --plt | |
static_code_analysis: | |
name: Static Code Analysis | |
needs: deps | |
runs-on: ubuntu-20.04 | |
env: | |
MIX_ENV: test | |
strategy: | |
matrix: | |
include: | |
- elixir: 1.13 | |
otp: 24 | |
- elixir: 1.14 | |
otp: 25 | |
steps: | |
- name: Cancel Previous Runs | |
uses: styfle/[email protected] | |
with: | |
access_token: ${{ github.token }} | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Setup | |
uses: erlef/setup-beam@v1 | |
with: | |
elixir-version: ${{ matrix.elixir }} | |
otp-version: ${{ matrix.otp }} | |
- name: Retrieve Cached Dependencies | |
uses: actions/cache@v3 | |
id: mix-cache | |
with: | |
path: | | |
deps | |
_build | |
priv/plts | |
key: ${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('mix.lock') }} | |
- name: Check Code Format | |
run: mix format --check-formatted | |
- name: Run Credo | |
run: mix credo | |
- name: Run Dialyzer | |
run: mix dialyzer --no-check --ignore-exit-status | |
unit_tests: | |
name: Unit Tests | |
needs: deps | |
runs-on: ubuntu-20.04 | |
env: | |
MIX_ENV: test | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- elixir: 1.13 | |
otp: 24 | |
- elixir: 1.14 | |
otp: 25 | |
steps: | |
- name: Cancel Previous Runs | |
uses: styfle/[email protected] | |
with: | |
access_token: ${{ github.token }} | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Setup | |
uses: erlef/setup-beam@v1 | |
with: | |
elixir-version: ${{ matrix.elixir }} | |
otp-version: ${{ matrix.otp }} | |
- name: Retrieve Cached Dependencies | |
uses: actions/cache@v3 | |
id: mix-cache | |
with: | |
path: | | |
deps | |
_build | |
priv/plts | |
key: ${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('mix.lock') }} | |
- name: Run test | |
run: mix test --trace --slowest 10 |