Skip to content

Commit ca77763

Browse files
committed
chore: cache restore for windows
1 parent 1388433 commit ca77763

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

Diff for: .github/workflows/ci.yml

+8-5
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,10 @@ jobs:
5656
- name: Checkout source
5757
uses: actions/checkout@v2
5858

59+
- name: Get yarn cache directory path
60+
id: yarn-cache-dir-path
61+
run: echo "::set-output name=dir::$(yarn cache dir)"
62+
5963
# Retain Node modules across builds; some packages download/build binaries
6064
# here.
6165
- name: Restore Node modules cache
@@ -74,11 +78,10 @@ jobs:
7478
uses: actions/cache@v2
7579
id: node-modules-cache-windows
7680
with:
77-
path: |
78-
node_modules
79-
packages\*\node_modules
80-
packages\*\.vscode-test
81-
key: ${{ runner.os }}-${{ matrix.node-version }}-node-modules-1-${{ hashFiles('yarn.lock')}}
81+
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
82+
key: ${{ runner.os }}-${{ matrix.node-version }}-yarn-${{ hashFiles('**/yarn.lock') }}
83+
restore-keys: |
84+
${{ runner.os }}-${{ matrix.node-version }}-yarn-
8285
8386
- name: Set up Node.js ${{ matrix.node-version }}
8487
uses: actions/setup-node@v1

0 commit comments

Comments
 (0)