3a6105a9349e230af942f6b233cb5ff6aca97d24
setup-elixir
This actions sets up an Elixir environment for use in Actions by:
- Installing OTP
- Installing Elixir
Note Currently, this action currently only supports Actions' ubuntu- runtimes.
Usage
See action.yml.
Note The OTP release version specification is relatively
complex.
For best results, we recommend specifying exact OTP and Elixir versions.
However, values like 22.x are also accepted, and we attempt to resolve them
according to semantic versioning rules.
Basic example
on: push
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-elixir@v1.2.0
with:
otp-version: 22.2
elixir-version: 1.9.4
- run: mix deps.get
- run: mix test
Matrix example
on: push
jobs:
test:
runs-on: ubuntu-latest
name: OTP ${{matrix.otp}} / Elixir ${{matrix.elixir}}
strategy:
matrix:
otp: [20.3, 21.3, 22.2]
elixir: [1.8.2, 1.9.4]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-elixir@v1.2.0
with:
otp-version: ${{matrix.otp}}
elixir-version: ${{matrix.elixir}}
- run: mix deps.get
- run: mix test
Phoenix example
on: push
jobs:
test:
runs-on: ubuntu-latest
services:
db:
image: postgres:11
ports: ['5432:5432']
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v2
- uses: actions/setup-elixir@v1.2.0
with:
otp-version: 22.2
elixir-version: 1.9.4
- run: mix deps.get
- run: mix test
License
The scripts and documentation in this project are released under the MIT license.
Contributing
Check out this doc.
Current Status
This action is in active development.
Description
Languages
JavaScript
78.1%
Elixir
14.5%
Shell
7.4%