Skip to content

Commit 899a530

Browse files
committed
chore: set .nvmrc and corepack
1 parent bde7eca commit 899a530

File tree

4 files changed

+10
-21
lines changed

4 files changed

+10
-21
lines changed

.github/workflows/ci.yml

+5-18
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Node.js CI
1+
name: CI
22

33
on:
44
push:
@@ -8,8 +8,6 @@ on:
88

99
jobs:
1010
test:
11-
if: "!contains(github.event.head_commit.message, 'ci skip')"
12-
1311
strategy:
1412
matrix:
1513
os: [ubuntu-latest]
@@ -21,23 +19,12 @@ jobs:
2119
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
2220
- uses: actions/checkout@v2
2321

24-
- uses: actions/setup-node@v2
25-
with:
26-
node-version: 14.x
22+
- run: corepack enable
2723

28-
- name: Cache ~/.pnpm-store
29-
uses: actions/cache@v2
30-
env:
31-
cache-name: cache-pnpm-store
24+
- uses: actions/setup-node@v2
3225
with:
33-
path: ~/.pnpm-store
34-
key: ${{ runner.os }}-${{ matrix.node-version }}-build-${{ env.cache-name }}-${{ hashFiles('**/pnpm-lock.yaml') }}
35-
restore-keys: |
36-
${{ runner.os }}-${{ matrix.node-version }}-build-${{ env.cache-name }}-
37-
${{ runner.os }}-${{ matrix.node-version }}-build-
38-
${{ runner.os }}-
39-
- name: Install pnpm
40-
run: npm i -g pnpm
26+
node-version-file: .nvmrc
27+
cache: pnpm
4128

4229
- name: Install deps
4330
run: pnpm i

.nvmrc

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
18

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name": "unplugin-swc",
33
"version": "0.0.0",
4+
"packageManager": "[email protected]",
45
"description": "SWC plugin for Vite and Rollup",
56
"publishConfig": {
67
"access": "public"

pnpm-lock.yaml

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)