From 5fc8caf75209a0789c3843aed1b512fb021489f1 Mon Sep 17 00:00:00 2001 From: Garry Hill Date: Wed, 6 Nov 2024 16:16:14 +0000 Subject: [PATCH] fix caching --- .github/workflows/elixir_tests.yml | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/.github/workflows/elixir_tests.yml b/.github/workflows/elixir_tests.yml index 189772a..3415cc9 100644 --- a/.github/workflows/elixir_tests.yml +++ b/.github/workflows/elixir_tests.yml @@ -27,7 +27,7 @@ jobs: version-file: ".tool-versions" - name: Restore dependencies cache - uses: actions/cache@v3 + uses: actions/cache/restore@v4 with: path: deps key: ${{ runner.os }}-mix-${{ hashFiles('mix.lock') }} @@ -44,6 +44,13 @@ jobs: - name: Install dependencies run: mix deps.get && mix deps.compile + - name: Cache dependencies + uses: actions/cache@v3 + with: + path: deps + key: ${{ runner.os }}-mix-${{ hashFiles('mix.lock') }} + restore-keys: ${{ runner.os }}-mix- + - name: Save compiled code uses: actions/cache/save@v4 with: @@ -66,11 +73,11 @@ jobs: with: version-type: strict version-file: ".tool-versions" - - name: Cache dependencies - id: cache-deps - uses: actions/cache@v4 + - name: Restore dependencies cache + uses: actions/cache/restore@v4 with: path: deps - key: ${{ runner.os }}-mixdeps-${{ hashFiles('mix.lock') }} + key: ${{ runner.os }}-mix-${{ hashFiles('mix.lock') }} + restore-keys: ${{ runner.os }}-mix- - run: mix deps.get - run: mix format --check-formatted