11name : CI
2-
32on :
43 push :
5- branches : [ main, master ]
4+ branches : [main, master]
65 pull_request :
7- branches : [ main, master ]
8-
6+ branches : [main, master]
97env :
108 MIX_ENV : test
119 ELIXIR_VERSION : ' 1.18'
1210 OTP_VERSION : ' 27.2'
13-
1411jobs :
1512 test :
1613 name : Test (Elixir ${{ matrix.elixir }} / OTP ${{ matrix.otp }})
1714 runs-on : ubuntu-latest
18-
1915 strategy :
2016 matrix :
2117 elixir : ['1.14', '1.15', '1.16', '1.17', '1.18']
@@ -33,73 +29,59 @@ jobs:
3329 otp : ' 27.0'
3430 - elixir : ' 1.16'
3531 otp : ' 27.0'
36-
3732 steps :
38- - name : Checkout code
39- uses : actions/checkout@v4
40-
41- - name : Set up Elixir
42- uses : erlef/setup-beam@v1
43- with :
44- elixir-version : ${{ matrix.elixir }}
45- otp-version : ${{ matrix.otp }}
46-
47- - name : Restore dependencies cache
48- uses : actions/cache@v4
49- with :
50- path : |
51- deps
52- _build
53- key : ${{ runner.os }}-mix-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }}
54- restore-keys : |
55- ${{ runner.os }}-mix-${{ matrix.otp }}-${{ matrix.elixir }}-
56-
57- - name : Install dependencies
58- run : mix deps.get
59-
60- - name : Check formatting
61- run : mix format --check-formatted
62-
63- - name : Run tests
64- run : mix test
65-
66- - name : Run Credo
67- run : mix credo --strict
68-
33+ - name : Checkout code
34+ uses : actions/checkout@v4
35+ - name : Set up Elixir
36+ uses : erlef/setup-beam@v1
37+ with :
38+ elixir-version : ${{ matrix.elixir }}
39+ otp-version : ${{ matrix.otp }}
40+ - name : Restore dependencies cache
41+ uses : actions/cache@v4
42+ with :
43+ path : |
44+ deps
45+ _build
46+ key : ${{ runner.os }}-mix-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }}
47+ restore-keys : |
48+ ${{ runner.os }}-mix-${{ matrix.otp }}-${{ matrix.elixir }}-
49+ - name : Install dependencies
50+ run : mix deps.get
51+ - name : Run tests
52+ run : mix test
53+ - name : Run Credo
54+ run : mix credo --strict
6955 dialyzer :
7056 name : Dialyzer
7157 runs-on : ubuntu-latest
72-
7358 steps :
74- - name : Checkout code
75- uses : actions/checkout@v4
76-
77- - name : Set up Elixir
78- uses : erlef/setup-beam@v1
79- with :
80- elixir-version : ${{ env.ELIXIR_VERSION }}
81- otp-version : ${{ env.OTP_VERSION }}
82-
83- - name : Restore dependencies cache
84- uses : actions/cache@v4
85- with :
86- path : |
87- deps
88- _build
89- key : ${{ runner.os }}-mix-${{ env.OTP_VERSION }}-${{ env.ELIXIR_VERSION }}-${{ hashFiles('**/mix.lock') }}
90- restore-keys : |
91- ${{ runner.os }}-mix-${{ env.OTP_VERSION }}-${{ env.ELIXIR_VERSION }}-
92-
93- - name : Restore PLT cache
94- uses : actions/cache@v4
95- with :
96- path : priv/plts
97- key : ${{ runner.os }}-plt-${{ env.OTP_VERSION }}-${{ env.ELIXIR_VERSION }}-${{ hashFiles('**/mix.lock') }}
98- restore-keys : |
99- ${{ runner.os }}-plt-${{ env.OTP_VERSION }}-${{ env.ELIXIR_VERSION }}-
100-
101- - name : Install dependencies
102- run : mix deps.get
103-
104- - name : Run Dialyzer
105- run : mix dialyzer
59+ - name : Checkout code
60+ uses : actions/checkout@v4
61+ - name : Set up Elixir
62+ uses : erlef/setup-beam@v1
63+ with :
64+ elixir-version : ${{ env.ELIXIR_VERSION }}
65+ otp-version : ${{ env.OTP_VERSION }}
66+ - name : Restore dependencies cache
67+ uses : actions/cache@v4
68+ with :
69+ path : |
70+ deps
71+ _build
72+ key : ${{ runner.os }}-mix-${{ env.OTP_VERSION }}-${{ env.ELIXIR_VERSION }}-${{ hashFiles('**/mix.lock') }}
73+ restore-keys : |
74+ ${{ runner.os }}-mix-${{ env.OTP_VERSION }}-${{ env.ELIXIR_VERSION }}-
75+ - name : Restore PLT cache
76+ uses : actions/cache@v4
77+ with :
78+ path : priv/plts
79+ key : ${{ runner.os }}-plt-${{ env.OTP_VERSION }}-${{ env.ELIXIR_VERSION }}-${{ hashFiles('**/mix.lock') }}
80+ restore-keys : |
81+ ${{ runner.os }}-plt-${{ env.OTP_VERSION }}-${{ env.ELIXIR_VERSION }}-
82+ - name : Install dependencies
83+ run : mix deps.get
84+ - name : Check formatting
85+ run : mix format --check-formatted
86+ - name : Run Dialyzer
87+ run : mix dialyzer
0 commit comments