-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add repository variable NOCACHE to disable CI-build caching
It is useful for debugging CI-build it simply doesn't use cache and cache is hold untouched
- Loading branch information
Showing
2 changed files
with
54 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: cache-status | ||
description: 'Get cache status' | ||
|
||
inputs: | ||
path: | ||
description: 'list of path for cache' | ||
default: '' | ||
key: | ||
description: 'cache key' | ||
default: '' | ||
outputs: | ||
cache-hit: | ||
description: 'output cache-hit' | ||
value: ${{ steps.cachecmd.outputs.cache-hit }} | ||
runs: | ||
using: composite | ||
steps: | ||
- name: Cache Optional Dependencies | ||
if: vars.NOCACHE != 'true' | ||
uses: actions/cache@v4 | ||
id: cachecmd | ||
with: | ||
path: ${{ inputs.path }} | ||
key: ${{ inputs.key }} | ||
- name: output value | ||
if: vars.NOCACHE == 'true' | ||
run: | | ||
echo "steps.cachecmd.outputs.cache-hit=false" >> $GITHUB_OUTPUT | ||
shell: bash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters