-
Notifications
You must be signed in to change notification settings - Fork 1
32 lines (30 loc) · 1007 Bytes
/
elixir.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Elixir CI
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
container:
image: elixir:1.16.2
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: deps
key: ${{ runner.os }}-mix-${{ hashFiles(format('{0}{1}', github.workspace, '/mix.lock')) }}
restore-keys: ${{ runner.os }}-mix-
- name: Init secrets file
run: |
cp config/secrets-example.exs config/secrets.exs
sed -i -e 's/private_key: ""/private_key: "0x4f3edf983ac636a65a842ce7c78d9aa706d3b113bce9c46f30d7d21715b23b1d"/g' config/secrets.exs
mix format config/secrets.exs
- name: Install Dependencies
run: |
mix local.rebar --force
mix local.hex --force
mix deps.get
- name: Check formatting
run: mix format --check-formatted
- name: Check code style
run: mix credo --strict
- name: Run tests
run: mix test --no-start