Skip to content

Commit

Permalink
better caching key
Browse files Browse the repository at this point in the history
  • Loading branch information
MahdiBM committed Jul 7, 2024
1 parent e862abf commit e2e97a0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ jobs:
uses: runs-on/cache/restore@v4
with:
path: .build
# e.g. 'syntax-kit-debug-build-Linux-c7008df8062ac4d5887ead9e59aa05829e'
key: "${{ github.event.repository.name }}-debug-build-${{ runner.os }}-${{ hashFiles('./Package.resolved') }}"
restore-keys: "${{ github.event.repository.name }}-debug-build-${{ runner.os }}-"
# e.g. 'syntax-kit-debug-build-swiftlang/swift:nightly-6.0-jammy-Linux-c7008df8062ac4d5887ead9e59aa05829e'
key: "${{ github.event.repository.name }}-debug-build-${{ matrix.swift-image }}-${{ runner.os }}-${{ hashFiles('./Package.resolved') }}"
restore-keys: "${{ github.event.repository.name }}-debug-build-${{ matrix.swift-image }}-${{ runner.os }}-"

- name: Build ${{ github.event.repository.name }}
run: swift build --build-tests
Expand All @@ -42,7 +42,7 @@ jobs:
uses: runs-on/cache/save@v4
with:
path: .build
key: "${{ github.event.repository.name }}-debug-build-${{ runner.os }}-${{ hashFiles('./Package.resolved') }}"
key: "${{ github.event.repository.name }}-debug-build-${{ matrix.swift-image }}-${{ runner.os }}-${{ hashFiles('./Package.resolved') }}"

- name: Run tests
run: swift test --enable-code-coverage --parallel
Expand Down

0 comments on commit e2e97a0

Please sign in to comment.