From 9be0f5596f6ead586d992f1a192029d782dd315f Mon Sep 17 00:00:00 2001 From: Daniel Widgren Date: Thu, 12 Feb 2026 08:08:58 +0100 Subject: [PATCH] ci: add build and test workflow Runs compile, eunit, ct, and dialyzer on OTP 28.0 / rebar3 3.26.0 for push and pull_request events. Co-Authored-By: Claude Opus 4.6 --- .github/workflows/erlang.yml | 37 ++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/erlang.yml diff --git a/.github/workflows/erlang.yml b/.github/workflows/erlang.yml new file mode 100644 index 0000000..84cb588 --- /dev/null +++ b/.github/workflows/erlang.yml @@ -0,0 +1,37 @@ +name: Build and test + +on: [push, pull_request] + +jobs: + build: + runs-on: ubuntu-24.04 + name: OTP ${{matrix.otp}} / rebar3 ${{matrix.rebar3}} + strategy: + fail-fast: false + matrix: + otp: ['28.0'] + rebar3: ['3.26.0'] + steps: + - uses: actions/checkout@v4 + - uses: erlef/setup-beam@v1 + with: + otp-version: ${{matrix.otp}} + rebar3-version: ${{matrix.rebar3}} + version-type: strict + - name: Cache rebar3 deps and build + uses: actions/cache@v4 + with: + path: | + ~/.cache/rebar3 + _build + key: ${{runner.os}}-rebar3-${{matrix.otp}}-${{matrix.rebar3}}-${{hashFiles('rebar.lock')}} + restore-keys: | + ${{runner.os}}-rebar3-${{matrix.otp}}-${{matrix.rebar3}}- + - name: Compile + run: rebar3 compile + - name: Run eunit + run: rebar3 eunit + - name: Run CT + run: rebar3 ct + - name: Run dialyzer + run: rebar3 dialyzer