Skip to content

Commit 3489819

Browse files
committed
ci: yarn 캐시 및 Corepack 설정 개선
- Corepack 설정 단계 추가 및 [email protected] 활성화 - yarn 캐시 디렉토리 경로를 가져오는 단계 추가 - yarn 의존성 캐싱을 위한 단계 추가 - 의존성 설치 명령어를 --inline-builds 옵션으로 수정
1 parent d2b7332 commit 3489819

File tree

1 file changed

+22
-7
lines changed

1 file changed

+22
-7
lines changed

.github/workflows/ci.yml

Lines changed: 22 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,19 +11,34 @@ jobs:
1111
runs-on: ubuntu-latest
1212

1313
steps:
14-
- uses: actions/checkout@v4
14+
- name: Checkout code
15+
uses: actions/checkout@v4
1516

16-
- name: Set up Node.js
17+
- name: Setup Node.js
1718
uses: actions/setup-node@v4
1819
with:
1920
node-version: '20'
20-
cache: 'yarn'
2121

22-
- name: Enable Corepack
23-
run: corepack enable
22+
- name: Setup Corepack
23+
run: |
24+
corepack enable
25+
corepack prepare [email protected] --activate
26+
27+
- name: Get yarn cache directory path
28+
id: yarn-cache-dir-path
29+
run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT
2430

25-
- name: Install dependencies
26-
run: yarn install --immutable --immutable-cache
31+
- name: Cache yarn dependencies
32+
uses: actions/cache@v4
33+
with:
34+
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
35+
key: yarn-cache-${{ hashFiles('**/yarn.lock') }}
36+
restore-keys: |
37+
yarn-cache-
38+
39+
- name: Install Dependencies
40+
run: |
41+
yarn install --immutable --inline-builds
2742
2843
- name: Build shared packages
2944
run: |

0 commit comments

Comments
 (0)