Skip to content

Commit

Permalink
ci: should setup node.js (#654)
Browse files Browse the repository at this point in the history
  • Loading branch information
himself65 authored Feb 10, 2025
1 parent f00b148 commit 69ec060
Showing 1 changed file with 9 additions and 23 deletions.
32 changes: 9 additions & 23 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,11 @@ jobs:

- uses: pnpm/action-setup@v4

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v4.2.0
name: Setup pnpm cache
- name: Setup Node.js
uses: actions/setup-node@v4
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
node-version: ${{ matrix.node-version }}
cache: 'pnpm'

- name: Install Dependencies
run: pnpm install --frozen-lockfile --prefer-offline
Expand All @@ -57,7 +50,7 @@ jobs:
timeout-minutes: 5
strategy:
matrix:
node-version: [18, 20]
node-version: [18, 20, 22]

name: Linux - Node ${{ matrix.node-version }}
steps:
Expand All @@ -67,18 +60,11 @@ jobs:

- uses: pnpm/action-setup@v4

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v4.2.0
name: Setup pnpm cache
- name: Setup Node.js
uses: actions/setup-node@v4
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
node-version: ${{ matrix.node-version }}
cache: 'pnpm'

- name: Install Dependencies
run: pnpm install --frozen-lockfile --prefer-offline
Expand Down

0 comments on commit 69ec060

Please sign in to comment.