Skip to content

Bump os in workflows #221

Bump os in workflows

Bump os in workflows #221

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
env:
MIX_ENV: test
TOKENIZERS_BUILD: "true"
jobs:
main:
runs-on: ubuntu-latest
name: "Test (${{ matrix.elixir_version }}, ${{ matrix.otp_version }})"
strategy:
fail-fast: false
matrix:
include:
- elixir_version: 1.18.3
otp_version: 27.3.3
lint: true
- elixir_version: 1.13.4
otp_version: 24.3.4
steps:
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: |
deps
_build
key: ${{ runner.os }}-mix-${{ matrix.elixir_version }}-${{matrix.otp_version}}-${{ hashFiles('**/mix.lock') }}
restore-keys: |
${{ runner.os }}-mix-${{ matrix.elixir_version }}-${{matrix.otp_version}}-
- uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
native/ex_tokenizers/target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
- uses: erlef/setup-beam@v1
with:
otp-version: ${{matrix.otp_version}}
elixir-version: ${{matrix.elixir_version}}
- run: mix deps.get
- run: mix format --check-formatted
if: ${{ matrix.lint }}
- run: mix deps.unlock --check-unused
if: ${{ matrix.lint }}
- run: mix deps.compile
- run: mix compile --warnings-as-errors
if: ${{ matrix.lint }}
- run: mix test