77jobs :
88 lint-test-sdk :
99 runs-on : ubuntu-latest
10+ strategy :
11+ matrix :
12+ node-version : [ '18', '20', '22', '23' ]
1013 steps :
1114 - uses : actions/checkout@v3
1215 - name : Use Node.js
1316 uses : actions/setup-node@v3
1417 with :
15- node-version : ' 18.x'
16- - uses : actions/cache@v2
18+ node-version : ${{ matrix.node-version }}
19+ - name : Get yarn cache directory path
20+ id : yarn-cache-dir-path
21+ run : echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
22+ - uses : actions/cache@v4
23+ id : yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
1724 with :
18- path : ' ./node_modules'
19- key : ${{ runner.os }}-root-node-modules-${{ hashFiles('./yarn.lock') }}
25+ path : ${{ steps.yarn-cache-dir-path.outputs.dir }}
26+ key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
27+ restore-keys : |
28+ ${{ runner.os }}-yarn-
2029 - name : ' Set up GCP SDK for downloading test data'
2130 uses : ' google-github-actions/setup-gcloud@v0'
2231 - name : Install SDK dependencies
@@ -30,16 +39,25 @@ jobs:
3039 working-directory : ./
3140 typecheck :
3241 runs-on : ubuntu-latest
42+ strategy :
43+ matrix :
44+ node-version : [ '18', '20', '22', '23' ]
3345 steps :
3446 - uses : actions/checkout@v3
3547 - name : Use Node.js
3648 uses : actions/setup-node@v3
3749 with :
38- node-version : ' 18.x'
39- - uses : actions/cache@v2
50+ node-version : ${{ matrix.node-version }}
51+ - name : Get yarn cache directory path
52+ id : yarn-cache-dir-path
53+ run : echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
54+ - uses : actions/cache@v4
55+ id : yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
4056 with :
41- path : ' ./node_modules'
42- key : ${{ runner.os }}-root-node-modules-${{ hashFiles('./yarn.lock') }}
57+ path : ${{ steps.yarn-cache-dir-path.outputs.dir }}
58+ key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
59+ restore-keys : |
60+ ${{ runner.os }}-yarn-
4361 - name : Install SDK dependencies
4462 run : yarn --frozen-lockfile
4563 working-directory : ./
0 commit comments