From 270043770cf8cbd46fc9c4be50797b6b49f9121d Mon Sep 17 00:00:00 2001 From: Andrew Mayorov Date: Tue, 4 Jan 2022 22:31:03 +0300 Subject: [PATCH] Add Erlang CI workflow (#5) Ensure workflow runs on master, so that PLT cache is available for future PRs. --- .github/workflows/erlang-pr.yml | 37 +++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/erlang-pr.yml diff --git a/.github/workflows/erlang-pr.yml b/.github/workflows/erlang-pr.yml new file mode 100644 index 0000000..8c5137e --- /dev/null +++ b/.github/workflows/erlang-pr.yml @@ -0,0 +1,37 @@ +name: Erlang +on: + pull_request: + branches: ['*'] + push: + branches: [master] + +jobs: + build: + name: Build and verify + runs-on: ubuntu-latest + steps: + + - uses: actions/checkout@v2 + + - uses: valitydev/action-setup-thrift@b457b89c7e1e960ea354f510bce69a725d16c556 + with: + thrift-version: '0.14.2' + + - uses: erlef/setup-beam@v1.9 + id: beam + with: + otp-version: '24' + rebar3-version: '3.18' + + - name: Restore PLT cache + uses: actions/cache@v2 + id: plt-cache + with: + key: | + ${{ runner.os }}-${{ steps.beam.outputs.otp-version }}-plt + path: | + _build/default/rebar3_*_plt + + - run: rebar3 compile + - run: rebar3 xref + - run: rebar3 dialyzer