gha save cache only on push events

This commit is contained in:
Labhansh Agrawal 2023-06-26 15:47:11 +05:30
parent 928209b914
commit ba91847cb5

View file

@ -99,6 +99,7 @@ jobs:
name: pr_num name: pr_num
path: ./pr_num.txt path: ./pr_num.txt
- uses: actions/cache/save@v3 - uses: actions/cache/save@v3
if: github.event_name == 'push'
with: with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock', 'app/yarn.lock') }} key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock', 'app/yarn.lock') }}