Clean cache directory after use (#95)
This commit is contained in:
parent
854bb539e1
commit
946776e670
1 changed files with 13 additions and 1 deletions
14
action.yml
14
action.yml
|
@ -59,7 +59,7 @@ runs:
|
|||
PACKAGES: "${{ inputs.packages }}"
|
||||
|
||||
- id: load-cache
|
||||
uses: actions/cache@v3
|
||||
uses: actions/cache/restore@v3
|
||||
with:
|
||||
path: ~/cache-apt-pkgs
|
||||
key: cache-apt-pkgs_${{ env.CACHE_KEY }}
|
||||
|
@ -83,6 +83,18 @@ runs:
|
|||
DEBUG: "${{ inputs.debug }}"
|
||||
PACKAGES: "${{ inputs.packages }}"
|
||||
|
||||
- id: save-cache
|
||||
if: ${{ ! steps.load-cache.outputs.cache-hit }}
|
||||
uses: actions/cache/save@v3
|
||||
with:
|
||||
path: ~/cache-apt-pkgs
|
||||
key: ${{ steps.load-cache.outputs.cache-primary-key }}
|
||||
|
||||
- id: clean-cache
|
||||
run: |
|
||||
rm -rf ~/cache-apt-pkgs
|
||||
shell: bash
|
||||
|
||||
- id: upload-logs
|
||||
if: ${{ inputs.debug == 'true' }}
|
||||
uses: actions/upload-artifact@v3
|
||||
|
|
Loading…
Reference in a new issue