-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
List of changes: - add more linting jobs - bump github/actions and selected deps used in CI - simplify Elixir/Erlang matrix in CI - set min Elixir requirement to 1.13 - use import Config
- Loading branch information
Showing
6 changed files
with
49 additions
and
105 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,81 +1,61 @@ | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
|
||
name: tests | ||
|
||
env: | ||
MIX_ENV: test | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-20.04 | ||
name: OTP ${{matrix.otp}} / Elixir ${{matrix.elixir}} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
otp: ["20.3", "21.3", "22.3", "23.3", "24.3", "25.2"] | ||
elixir: ["1.10.4", "1.11.4", "1.12.3", "1.13.4", "1.14.3"] | ||
exclude: | ||
# Supporter Erlang/OTP versions | ||
# Elixir 1.10 ; erlang 21 - 22 (23 from v1.10.3) | ||
- otp: "20.3" | ||
elixir: "1.10.4" | ||
- otp: "24.3" | ||
elixir: "1.10.4" | ||
- otp: "25.2" | ||
elixir: "1.10.4" | ||
- otp: "23.3" | ||
elixir: "1.10.4" | ||
# Elixir 1.11 ; erlang 21 - 23 (24 from v1.11.4) | ||
- otp: "20.3" | ||
elixir: "1.11.4" | ||
- otp: "25.2" | ||
elixir: "1.11.4" | ||
# Elixir 1.12 ; erlang 22 - 24 | ||
- otp: "20.3" | ||
elixir: "1.12.3" | ||
- otp: "21.3" | ||
elixir: "1.12.3" | ||
- otp: "25.2" | ||
elixir: "1.12.3" | ||
# Elixir 1.13 ; erlang 22 - 24 (25 from 1.13.4) | ||
- otp: "20.3" | ||
elixir: "1.13.4" | ||
- otp: "21.3" | ||
elixir: "1.13.4" | ||
# Elixir 1.14 ; erlang 23 - 25 | ||
- otp: "20.3" | ||
elixir: "1.14.3" | ||
- otp: "21.3" | ||
elixir: "1.14.3" | ||
- otp: "22.3" | ||
elixir: "1.14.3" | ||
include: | ||
- pair: | ||
elixir: "1.13" | ||
otp: "22" | ||
- pair: | ||
elixir: "1.17" | ||
otp: "27" | ||
lint: lint | ||
env: | ||
MIX_ENV: test | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v4 | ||
- uses: erlef/setup-beam@v1 | ||
with: | ||
otp-version: ${{matrix.otp}} | ||
elixir-version: ${{matrix.elixir}} | ||
- name: Cache deps | ||
uses: actions/cache@v3 | ||
with: | ||
path: deps | ||
key: ${{ runner.os }}-deps-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }} | ||
restore-keys: ${{ runner.os }}-deps-${{ matrix.otp }}-${{ matrix.elixir }}- | ||
- name: Cache build | ||
uses: actions/cache@v3 | ||
with: | ||
path: _build | ||
key: ${{ runner.os }}-build-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }} | ||
restore-keys: ${{ runner.os }}-build-${{ matrix.otp }}-${{ matrix.elixir }}- | ||
otp-version: ${{matrix.pair.otp}} | ||
elixir-version: ${{matrix.pair.elixir}} | ||
# - name: Cache deps | ||
# uses: actions/cache@v4 | ||
# with: | ||
# path: deps | ||
# key: ${{ runner.os }}-deps-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }} | ||
# restore-keys: ${{ runner.os }}-deps-${{ matrix.otp }}-${{ matrix.elixir }}- | ||
# - name: Cache build | ||
# uses: actions/cache@v4 | ||
# with: | ||
# path: _build | ||
# key: ${{ runner.os }}-build-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }} | ||
# restore-keys: ${{ runner.os }}-build-${{ matrix.otp }}-${{ matrix.elixir }}- | ||
|
||
- run: mix deps.get | ||
|
||
- run: mix deps.unlock --check-unused | ||
if: ${{ matrix.lint }} | ||
|
||
- run: mix compile --warnings-as-errors | ||
|
||
- run: mix format --check-formatted | ||
if: ${{ matrix.lint }} | ||
|
||
- run: mix credo --strict | ||
if: ${{ matrix.lint }} | ||
|
||
- run: mix coveralls.github | ||
|
||
- run: mix dialyzer | ||
if: ${{ matrix.lint }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,3 @@ | ||
# This file is responsible for configuring your application | ||
# and its dependencies with the aid of the Mix.Config module. | ||
use Mix.Config | ||
import Config | ||
|
||
# This configuration is loaded before any dependency and is restricted | ||
# to this project. If another project depends on this project, this | ||
# file won't be loaded nor affect the parent project. For this reason, | ||
# if you want to provide default values for your application for | ||
# 3rd-party users, it should be done in your "mix.exs" file. | ||
|
||
# You can configure for your application as: | ||
# | ||
# config :ueberauth_auth0, key: :value | ||
# | ||
# And access this configuration in your application as: | ||
# | ||
# Application.get_env(:ueberauth_auth0, :key) | ||
# | ||
# Or configure a 3rd-party app: | ||
# | ||
# config :logger, level: :info | ||
# | ||
|
||
# It is also possible to import configuration files, relative to this | ||
# directory. For example, you can emulate configuration per environment | ||
# by uncommenting the line below and defining dev.exs, test.exs and such. | ||
# Configuration from the imported file will override the ones defined | ||
# here (which is why it is important to import them last). | ||
# | ||
# import_config "#{Mix.env}.exs" | ||
if Mix.env() == :test, do: import_config("test.exs") | ||
if config_env() == :test, do: import_config("test.exs") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
use Mix.Config | ||
import Config | ||
|
||
config :ueberauth, Ueberauth, | ||
json_library: Jason, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters