@@ -46,15 +46,11 @@ jobs:
4646 - name : Fetch submodule tags
4747 working-directory : compiler
4848 run : git fetch --tags https://github.com/google/closure-compiler.git
49- - name : Get yarn cache directory path
50- run : echo "yarn_cache_dir=$(yarn cache dir)" >> $GITHUB_ENV
51- - name : Yarn and maven cache
52- uses : actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # 4.2.3
53- with :
54- path : |
55- ${{ env.yarn_cache_dir }}
56- ~/.m2/repository
57- key : ${{ runner.os }}-yarn-mvn-java11-${{ hashFiles('**/yarn.lock', '**/pom.xml') }}
49+ - name : Use Node.js ${{ env.NODE_VERSION }}
50+ uses : actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # 4.4.0
51+ with :
52+ node-version : ${{ env.NODE_VERSION }}
53+ cache : yarn
5854 - name : Install packages
5955 run : yarn install --colors=always
6056 - name : Build jar
10399 uses : actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # 4.4.0
104100 with :
105101 node-version : ${{ env.NODE_VERSION }}
102+ cache : yarn
106103 - uses : graalvm/setup-graalvm@01ed653ac833fe80569f1ef9f25585ba2811baab # 1.3.3
107104 with :
108105 java-version : 21
@@ -124,16 +121,6 @@ jobs:
124121 with :
125122 name : Externs folder
126123 path : packages/google-closure-compiler/externs
127- - name : Get yarn cache directory path
128- run : echo "yarn_cache_dir=$(yarn cache dir)" >> $GITHUB_ENV
129- - name : Cache yarn
130- uses : actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # 4.2.3
131- id : yarn-cache
132- with :
133- path : ${{ env.yarn_cache_dir }}
134- key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
135- restore-keys : |
136- ${{ runner.os }}-yarn-
137124 - name : Install packages
138125 run : yarn install --colors=always
139126 - name : Build image
@@ -174,6 +161,7 @@ jobs:
174161 uses : actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # 4.4.0
175162 with :
176163 node-version : ${{ env.NODE_VERSION }}
164+ cache : yarn
177165 - uses : graalvm/setup-graalvm@01ed653ac833fe80569f1ef9f25585ba2811baab # 1.3.3
178166 with :
179167 java-version : 21
@@ -195,16 +183,6 @@ jobs:
195183 with :
196184 name : Externs folder
197185 path : packages/google-closure-compiler/externs
198- - name : Get yarn cache directory path
199- run : echo "yarn_cache_dir=$(yarn cache dir)" >> $GITHUB_ENV
200- - name : Cache yarn
201- uses : actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # 4.2.3
202- id : yarn-cache
203- with :
204- path : ${{ env.yarn_cache_dir }}
205- key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
206- restore-keys : |
207- ${{ runner.os }}-yarn-
208186 - name : Install packages
209187 run : yarn install --colors=always
210188 - name : Build image
@@ -243,6 +221,7 @@ jobs:
243221 uses : actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # 4.4.0
244222 with :
245223 node-version : ${{ env.NODE_VERSION }}
224+ cache : yarn
246225 - uses : graalvm/setup-graalvm@01ed653ac833fe80569f1ef9f25585ba2811baab # 1.3.3
247226 with :
248227 java-version : 21
@@ -264,16 +243,6 @@ jobs:
264243 with :
265244 name : Externs folder
266245 path : packages/google-closure-compiler/externs
267- - name : Get yarn cache directory path
268- run : echo "yarn_cache_dir=$(yarn cache dir)" >> $GITHUB_ENV
269- - name : Cache yarn
270- uses : actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # 4.2.3
271- id : yarn-cache
272- with :
273- path : ${{ env.yarn_cache_dir }}
274- key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
275- restore-keys : |
276- ${{ runner.os }}-yarn-
277246 - name : Install packages
278247 run : yarn install --colors=always
279248 - name : Build image
@@ -312,6 +281,7 @@ jobs:
312281 uses : actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # 4.4.0
313282 with :
314283 node-version : ${{ env.NODE_VERSION }}
284+ cache : yarn
315285 - uses : graalvm/setup-graalvm@01ed653ac833fe80569f1ef9f25585ba2811baab # 1.3.3
316286 with :
317287 java-version : 21
@@ -333,17 +303,6 @@ jobs:
333303 with :
334304 name : Externs folder
335305 path : packages/google-closure-compiler/externs
336- - name : Get yarn cache directory path
337- # See https://stackoverflow.com/a/66737579/1211524
338- run : echo "yarn_cache_dir=$(yarn cache dir)" >> $env:GITHUB_ENV
339- - name : Cache yarn
340- uses : actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # 4.2.3
341- id : yarn-cache
342- with :
343- path : ${{ env.yarn_cache_dir }}
344- key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
345- restore-keys : |
346- ${{ runner.os }}-yarn-
347306 - name : Install packages
348307 run : yarn install --colors=always
349308 - name : Build image
@@ -385,6 +344,7 @@ jobs:
385344 with :
386345 node-version : ${{ env.NODE_VERSION }}
387346 registry-url : https://registry.npmjs.org/
347+ cache : yarn
388348 - name : Download compiler jar
389349 uses : actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # 4.3.0
390350 with :
@@ -426,16 +386,6 @@ jobs:
426386 chmod 755 packages/google-closure-compiler-linux-arm64/compiler
427387 chmod 755 packages/google-closure-compiler-macos/compiler
428388 chmod 755 packages/google-closure-compiler-windows/compiler.exe
429- - name : Get yarn cache directory path
430- run : echo "yarn_cache_dir=$(yarn cache dir)" >> $GITHUB_ENV
431- - name : Cache yarn
432- uses : actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # 4.2.3
433- id : yarn-cache
434- with :
435- path : ${{ env.yarn_cache_dir }}
436- key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
437- restore-keys : |
438- ${{ runner.os }}-yarn-
439389 - name : Install packages
440390 run : yarn install --colors=always
441391 - name : Prepare for publish
0 commit comments