Ignore .vscode folder #45
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
name: CI | |
on: | |
push: | |
jobs: | |
build: | |
name: Build and test | |
runs-on: ubuntu-latest | |
timeout-minutes: 15 | |
env: | |
APP_NAME: jehovakel_ex_times | |
TZ: Europe/Berlin | |
LANG: de_DE.UTF-8 | |
LC_ALL: de_DE.UTF-8 | |
ELIXIR_VERSION: 1.14.3 | |
ERLANG_VERSION: 25.2 | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c | |
- name: Set up Elixir | |
uses: erlef/setup-beam@1f06ac36d31fecd50acdec4ef7bfd5dc7346f187 | |
with: | |
elixir-version: ${{ env.ELIXIR_VERSION }} | |
otp-version: ${{ env.ERLANG_VERSION }} | |
- name: Restore Elixir dependencies cache | |
uses: actions/cache@58c146cc91c5b9e778e71775dfe9bf1442ad9a12 | |
with: | |
path: | | |
deps | |
_build | |
!_build/test/lib/${{ env.APP_NAME }} | |
key: ${{ runner.os }}-mix-${{ hashFiles('mix.lock') }} | |
restore-keys: ${{ runner.os }}-mix- | |
- name: Install dependencies | |
run: mix do deps.get, deps.compile | |
- name: Run static analysis | |
if: github.ref == 'refs/heads/main' | |
run: | | |
mix format --check-formatted | |
mix compile --warnings-as-errors | |
mix credo | |
- name: Run tests | |
run: mix test |