ci: setup cache for yarn
This commit is contained in:
1 parent
dc768e0ba9
commit
93fd8aedb3
1 file changed
+13
@@ -29,6 +29,19 @@ runs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
run: node scripts/module-resolve/ci.cjs
|
run: node scripts/module-resolve/ci.cjs
|
||||||
|
|
||||||
|
- name: Get yarn cache directory path
|
||||||
|
id: yarn-cache-dir-path
|
||||||
|
shell: bash
|
||||||
|
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
|
||||||
|
|
||||||
|
- uses: actions/cache@v3
|
||||||
|
id: yarn-cache
|
||||||
|
with:
|
||||||
|
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
|
||||||
|
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-yarn-
|
||||||
|
|
||||||
- name: yarn install
|
- name: yarn install
|
||||||
if: ${{ inputs.package-install == 'true' }}
|
if: ${{ inputs.package-install == 'true' }}
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
|
|||||||
Reference in new issue
Block a user