.github: remove github.job from the cache key and update docs
This commit adds a more descriptive docs about the caching process. In addition, the `github.job` is now removed from the cache key construction to allow jobs sharing the same cache. In addition, given we now use `inputs.key-prefix`, the `github.job` is no longer relevant as the `key-prefix` already creates a unique name for the cache. We also update the lint and check commits job to use the same cache from the unit test, given they are running in the same environment.
This commit is contained in:
2 files changed
+37
-4
No files matched your search
@@ -126,6 +126,8 @@ jobs:
|
||||
uses: ./.github/actions/setup-go
|
||||
with:
|
||||
go-version: '${{ env.GO_VERSION }}'
|
||||
# Use the same cache from unit test job to save time.
|
||||
key-prefix: unit-test
|
||||
|
||||
- name: fetch and rebase on ${{ github.base_ref }}
|
||||
uses: ./.github/actions/rebase
|
||||
@@ -152,6 +154,8 @@ jobs:
|
||||
uses: ./.github/actions/setup-go
|
||||
with:
|
||||
go-version: '${{ env.GO_VERSION }}'
|
||||
# Use the same cache from unit test job to save time.
|
||||
key-prefix: unit-test
|
||||
|
||||
- name: lint
|
||||
run: GOGC=50 make lint
|
||||
|
||||
Reference in new issue
Block a user