From 4dd19acfab716706c406bf485a52b3f9afaf5187 Mon Sep 17 00:00:00 2001 From: Daniel Wu Date: Sun, 29 Oct 2023 18:15:29 -0400 Subject: [PATCH] update workflow --- .github/workflows/node.js.yml | 27 +++++++++++++++++++++------ serverless/pnpm-workspace.yaml | 2 -- 2 files changed, 21 insertions(+), 8 deletions(-) delete mode 100644 serverless/pnpm-workspace.yaml diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 80a0c2f15..4a6a8b188 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -21,15 +21,30 @@ jobs: steps: - uses: actions/checkout@v3 + + - name: Install Node.js + uses: actions/setup-node@v3 + with: + node-version: matrix.node-version + + - uses: pnpm/action-setup@v2 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV - uses: actions/cache@v3 with: - path: "**/node_modules" - key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-modules-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- - name: Install dependencies - if: steps.cache-yarn-cache.outputs.cache-hit != 'true' - run: yarn install - working-directory: ./frontend - - run: yarn lint + run: pnpm install working-directory: ./frontend # future: add yarn build once build errors are resolved diff --git a/serverless/pnpm-workspace.yaml b/serverless/pnpm-workspace.yaml deleted file mode 100644 index a4e134d3e..000000000 --- a/serverless/pnpm-workspace.yaml +++ /dev/null @@ -1,2 +0,0 @@ -packages: - - "packages/**/*"