Skip to content

Commit 49a1d2d

Browse files
committed
chore: setup pnpm ci
1 parent 012b87f commit 49a1d2d

File tree

1 file changed

+29
-10
lines changed

1 file changed

+29
-10
lines changed

.github/workflows/ci.yml

+29-10
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,33 @@ jobs:
1212
runs-on: ubuntu-latest
1313

1414
steps:
15-
# Permitir o acesso ao código da aplicação
16-
- uses: actions/checkout@v4
17-
18-
# Fazer o setup do node para rodar a aplicação
19-
- uses: actions/setup-node@v4
20-
with:
21-
node-version: 20
22-
cache: 'yarn'
23-
- run: yarn
24-
- run: yarn run test
15+
- name: Checkout
16+
uses: actions/checkout@v4
17+
18+
- name: Install Node.js
19+
uses: actions/setup-node@v4
20+
with:
21+
node-version: 20
22+
23+
- uses: pnpm/action-setup@v4
24+
name: Install pnpm
25+
with:
26+
version: 8
27+
run_install: false
28+
29+
- name: Get pnpm store directory
30+
shell: bash
31+
run: |
32+
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
33+
34+
- uses: actions/cache@v4
35+
name: Setup pnpm cache
36+
with:
37+
path: ${{ env.STORE_PATH }}
38+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
39+
restore-keys: |
40+
${{ runner.os }}-pnpm-store-
41+
42+
- name: Install dependencies
43+
run: pnpm install
2544

0 commit comments

Comments
 (0)