mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-07-25 17:21:51 -07:00
ci: Discard old caches to fix build failures
We're getting "undefined reference" errors during linking, suggesting some build artifacts in the cache are stale and need to be rebuilt.
This commit is contained in:
9
.github/workflows/stack.yml
vendored
9
.github/workflows/stack.yml
vendored
@@ -67,17 +67,17 @@ jobs:
|
||||
- name: Refresh caches once a month
|
||||
id: cache-date
|
||||
# GHA writes caches on the first miss and then never updates them again;
|
||||
# force updating the cache at least once a month
|
||||
# force updating the cache at least once a month. Additionally, the
|
||||
# date is prefixed with an epoch number to let us manually refresh the
|
||||
# cache when needed. This is a workaround for https://github.com/actions/cache/issues/2
|
||||
run: |
|
||||
echo "::set-output name=date::$(date +%Y-%m)"
|
||||
echo "::set-output name=date::1-$(date +%Y-%m)"
|
||||
|
||||
- name: Cache Haskell package metadata
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: ~/.stack/pantry
|
||||
key: stack-pantry-${{ runner.os }}-${{ steps.cache-date.outputs.date }}
|
||||
restore-keys: |
|
||||
stack-pantry-${{ runner.os }}-
|
||||
|
||||
- name: Cache Haskell dependencies
|
||||
uses: actions/cache@v2
|
||||
@@ -90,7 +90,6 @@ jobs:
|
||||
restore-keys: |
|
||||
stack-${{ runner.os }}-${{ matrix.resolver }}-${{ steps.cache-date.outputs.date }}-${{ hashFiles(matrix.yaml) }}-
|
||||
stack-${{ runner.os }}-${{ matrix.resolver }}-${{ steps.cache-date.outputs.date }}-
|
||||
stack-${{ runner.os }}-${{ matrix.resolver }}-
|
||||
|
||||
- name: Update hackage index
|
||||
# always update index to prevent the shared ~/.stack/pantry cache from being empty
|
||||
|
Reference in New Issue
Block a user