From 441a6a0f5d3c5f3c1f679ac9669f2e171b5b37b0 Mon Sep 17 00:00:00 2001 From: Shun Kashiwa Date: Sun, 15 Sep 2024 17:53:37 -0700 Subject: [PATCH] use corepack on GH Actions --- .github/workflows/push.yml | 42 +++++++++++++++++++------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 2736131..667a716 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -8,25 +8,18 @@ jobs: working-directory: Web steps: - uses: actions/checkout@v4 - - uses: actions/setup-node@v2 + - uses: actions/setup-node@v4 with: - node-version: "20" - - uses: pnpm/action-setup@v3 - name: Install pnpm - with: - version: 8 - run_install: false + node-version: "22" + cache: "pnpm" + - name: Enable corepack + run: | + corepack enable && + corepack install - name: Get pnpm store directory shell: bash run: | echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV - - uses: actions/cache@v3 - name: Setup pnpm cache - with: - path: ${{ env.STORE_PATH }} - key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} - restore-keys: | - ${{ runner.os }}-pnpm-store- - name: Install run: pnpm install - name: Format @@ -44,12 +37,14 @@ jobs: working-directory: Web steps: - uses: actions/checkout@v4 - - uses: actions/setup-node@v2 + - uses: actions/setup-node@v4 with: - node-version: "20" - - uses: pnpm/action-setup@v3 - with: - version: 8 + node-version: "22" + cache: "pnpm" + - name: Enable corepack + run: | + corepack enable && + corepack install - name: pnpm Build run: pnpm install - name: Build Checker @@ -71,9 +66,14 @@ jobs: working-directory: Web steps: - uses: actions/checkout@v4 - - uses: actions/setup-node@v2 + - uses: actions/setup-node@v4 with: - node-version: "20" + node-version: "22" + cache: "pnpm" + - name: Enable corepack + run: | + corepack enable && + corepack install - uses: pnpm/action-setup@v3 with: version: 8