Skip to content

Commit ea1c47b

Browse files
committed
Use Github Actions instead of Travis CI
Also change Dependabot frequency to monthly, and add updates for Github Actions. Also include Dialyxir in the "test" Mix environment, not just "dev".
1 parent 98f53ed commit ea1c47b

File tree

4 files changed

+57
-24
lines changed

4 files changed

+57
-24
lines changed

.github/dependabot.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ updates:
33
- package-ecosystem: mix
44
directory: "/"
55
schedule:
6-
interval: daily
7-
time: "04:00"
8-
open-pull-requests-limit: 10
6+
interval: monthly
7+
- package-ecosystem: "github-actions"
8+
directory: "/"
9+
schedule:
10+
interval: monthly
11+
groups:
12+
gh-actions:
13+
patterns:
14+
- "*"

.github/workflows/ci.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Test
2+
3+
on: push
4+
5+
env:
6+
MIX_ENV: test
7+
OTP_VER: '26.1'
8+
ELIXIR_VER: '1.16.1'
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v5
15+
- name: Setup Erlang/Elixir
16+
uses: erlef/setup-beam@v1
17+
with:
18+
otp-version: ${{ env.OTP_VER }}
19+
elixir-version: ${{ env.ELIXIR_VER }}
20+
version-type: strict
21+
22+
- name: Cache plt
23+
uses: actions/cache@v4
24+
with:
25+
path: |
26+
~/.mix
27+
_build/dev
28+
_build/test
29+
!_build/dev/lib
30+
!_build/test/lib
31+
key: plt_erlang-${{ env.OTP_VER }}_elixir-${{ env.ELIXIR_VER }}
32+
restore-keys: plt_erlang-${{ env.OTP_VER }}_elixir-${{ env.ELIXIR_VER }}
33+
34+
- name: Get dependencies
35+
run: mix deps.get
36+
37+
- name: Compile
38+
run: mix compile
39+
40+
- name: Test
41+
run: mix test
42+
43+
- name: Credo
44+
run: mix credo
45+
46+
- name: Run dialyzer
47+
run: mix dialyzer

.travis.yml

Lines changed: 0 additions & 20 deletions
This file was deleted.

mix.exs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ defmodule TelemetryMetricsStatman.MixProject do
2323
[
2424
{:telemetry_metrics, "~> 0.6.2 or ~> 1.0"},
2525
{:statman, github: "GameAnalytics/statman", tag: "v0.13"},
26-
{:dialyxir, "~> 1.0", only: [:dev], runtime: false},
26+
{:dialyxir, "~> 1.0", only: [:dev, :test], runtime: false},
2727
{:credo, "~> 1.4", only: [:dev, :test], runtime: false},
2828
{:mock, "~> 0.3", only: :test},
2929
]

0 commit comments

Comments
 (0)