Skip to content

Commit d387b62

Browse files
feat: use local cache action
1 parent 24d40ac commit d387b62

1 file changed

Lines changed: 8 additions & 12 deletions

File tree

action.yml

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -78,30 +78,26 @@ runs:
7878
otp-version: ${{ inputs.otp-version }}
7979

8080
- name: Get deps cache
81-
uses: actions/cache@v4
81+
uses: corca-ai/local-cache@v2
8282
with:
83+
base: /home/runner/.cache/actions
8384
path: deps/
84-
key: deps-${{ inputs.cache-key }}-${{ runner.os }}-${{ hashFiles('**/mix.lock') }}
85-
restore-keys: |
86-
deps-${{ inputs.cache-key }}-${{ runner.os }}-
85+
key: deps-${{ runner.os }}-${{ hashFiles('**/mix.lock') }}
8786

8887
- name: Get build cache
89-
uses: actions/cache@v4
90-
id: build-cache
88+
uses: corca-ai/local-cache@v2
9189
with:
90+
base: /home/runner/.cache/actions
9291
path: _build/${{env.MIX_ENV}}/
93-
key: build-${{ inputs.cache-key }}-${{ runner.os }}-${{ inputs.otp-version }}-${{ inputs.elixir-version }}-${{ env.MIX_ENV }}-${{ hashFiles('**/mix.lock') }}
94-
restore-keys: |
95-
build-${{ inputs.cache-key }}-${{ runner.os }}-${{ inputs.otp-version }}-${{ inputs.elixir-version }}-${{ env.MIX_ENV }}-
92+
key: build--${{ runner.os }}-${{ inputs.otp-version }}-${{ inputs.elixir-version }}-${{ env.MIX_ENV }}-${{ hashFiles('**/mix.lock') }}
9693

9794
- name: Get Hex cache
98-
uses: actions/cache@v4
95+
uses: corca-ai/local-cache@v2
9996
id: hex-cache
10097
with:
98+
base: /home/runner/.cache/actions
10199
path: ~/.hex
102100
key: build-${{ runner.os }}-${{ inputs.otp-version }}-${{ inputs.elixir-version }}-${{ hashFiles('**/mix.lock') }}
103-
restore-keys: |
104-
build-${{ runner.os }}-${{ inputs.otp-version }}-${{ inputs.elixir-version }}-
105101

106102
# In my experience, I have issues with incremental builds maybe 1 in 100
107103
# times that are fixed by doing a full recompile.

0 commit comments

Comments
 (0)