# Setup-BEAM - GitHub Action

**URL:** <https://erlangforums.com/t/setup-beam-github-action/929>\
**Category:** BEAM Interoperability\
**Tags:** github\
**Created:** [January 12, 2022, 11:05pm UTC](https://erlangforums.com/t/setup-beam-github-action/929 "2022-01-12T23:05:24Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![vkatsuba](https://erlangforums.com/user_avatar/erlangforums.com/vkatsuba/32/314_2.png) [@vkatsuba](https://erlangforums.com/u/vkatsuba)\
**Post date:** [January 12, 2022, 11:05pm UTC](https://erlangforums.com/t/setup-beam-github-action/929/1 "2022-01-12T23:05:24Z")

</div>

> **[GitHub - erlef/setup-beam: Set up your BEAM-based GitHub Actions workflow...](https://github.com/erlef/setup-beam)**
>
> Set up your BEAM-based GitHub Actions workflow (Erlang, Elixir, Gleam, ...) - GitHub - erlef/setup-beam: Set up your BEAM-based GitHub Actions workflow (Erlang, Elixir, Gleam, ...)

Hi folks! I want share with you with amazing tool for [GitHub Actions](https://github.com/features/actions) for integration CI/CD into your Erlang Open Source project 🤘. In order to start using this tool in your Erlang project in GitHub you need to follow the next steps:

- Create folder `.github` inside of your root project folder
- Inside of `.github` you need create new folder `workflows`
- Inside of `workflows` you need create `ci.yaml` or `ci.yml` or you can use any other name of `YAML` file 🤪

Then you can add something like:

```nohighlight
name: CI

on:
  push:
  pull_request:
    branches: [$default-branch]
  release:
    types:
      - created
  workflow_dispatch:

jobs:
  ubuntu:
    name: "Ubuntu"
    runs-on: ubuntu-latest
    strategy:
      matrix:
        otp: [23.3, 24.1]
        rebar: [3.17.0]
    steps:
    - uses: actions/checkout@v2
    - uses: erlef/setup-beam@v1
      with:
        otp-version: ${{matrix.otp}}
        rebar3-version: ${{matrix.rebar}}
    - name: Tests
      run: rebar3 ct

```

And this is it!(Don’t forgot push it into GitHub project 😜)

What test your project in **Windows**? Not a problem, try it:

```nohighlight
  windows:
    name: "Windows"
    runs-on: windows-latest
    strategy:
      matrix:
        otp: [23.3, 24.1]
        rebar: [3.17.0]
    steps:
    - uses: actions/checkout@v2
    - uses: erlef/setup-beam@v1
      with:
        otp-version: ${{matrix.otp}}
        rebar3-version: ${{matrix.rebar}}
    - name: Tests
      run: rebar3 ct

```

If you have a mix project with Elixir or by some any other reason you use Elixir - the **Setup-BEAM** is also suite for you - just follow the steps in [README#example-erlangotp–elixir-on-ubuntu](https://github.com/erlef/setup-beam#example-erlangotp--elixir-on-ubuntu)!

---

<div class="post-metadata">

**Author:** ![vkatsuba](https://erlangforums.com/user_avatar/erlangforums.com/vkatsuba/32/314_2.png) [@vkatsuba](https://erlangforums.com/u/vkatsuba)\
**Post date:** [January 12, 2022, 11:09pm UTC](https://erlangforums.com/t/setup-beam-github-action/929/2 "2022-01-12T23:09:25Z")

</div>

> **[Release v1.10.0 · erlef/setup-beam](https://github.com/erlef/setup-beam/releases/tag/v1.10.0)**
>
> Merged pull requests
> 
> \#75 - Mention what problem matchers do in the README
> \#81 - Make OTP installation optional (if targeting Gleam)
> \#82 - Automate updating 3rd party licenses
> \#83 - Prevent depreca...

> The @paulo-f-oliveira was provide new release of `setup-beam v1.10.0` few hours ago 🥳!

# Highlights:

- optional OTP installation
- allow for `rebar3` nightly builds

Enjoy 🤘

---

<div class="post-metadata">

**Author:** ![starbelly](https://erlangforums.com/user_avatar/erlangforums.com/starbelly/32/209_2.png) [@starbelly](https://erlangforums.com/u/starbelly)\
**Post date:** [January 13, 2022, 12:33am UTC](https://erlangforums.com/t/setup-beam-github-action/929/3 "2022-01-13T00:33:52Z")

</div>

Adding a note for this, it’s in the README, but if anyone comes along this thread it should duly noted that optional otp installation is only currently applicable when using gleam.
