Skip to content

Commit cde5ca4

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

1 file changed

Lines changed: 6 additions & 18 deletions

File tree

action.yml

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -78,30 +78,18 @@ 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 }}-
96-
97-
- name: Get Hex cache
98-
uses: actions/cache@v4
99-
id: hex-cache
100-
with:
101-
path: ~/.hex
102-
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 }}-
92+
key: build-${{ runner.os }}-${{ inputs.otp-version }}-${{ inputs.elixir-version }}-${{ env.MIX_ENV }}-${{ hashFiles('**/mix.lock') }}
10593

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

0 commit comments

Comments
 (0)