19
19
# and changed to use pnpm first
20
20
21
21
jobs :
22
- setup_pnpm :
23
- runs-on : ubuntu-latest
24
- steps :
25
- - name : Setup pnpm
26
- uses : pnpm/action-setup@v4
27
- with :
28
- version : 9
29
-
30
22
dependency-review :
31
- needs : [setup_pnpm]
32
23
name : Dependency Review
33
24
if : github.event_name == 'pull_request'
34
25
runs-on : ubuntu-latest
@@ -46,13 +37,16 @@ jobs:
46
37
license-check :
47
38
if : >
48
39
!failure() &&
49
- !cancelled() &&
50
- inputs.license-check == true
40
+ !cancelled()
51
41
name : Check Licenses
52
42
runs-on : ubuntu-latest
53
43
permissions :
54
44
contents : read
55
45
steps :
46
+ - uses : pnpm/action-setup@v4
47
+ with :
48
+ version : 9
49
+
56
50
- uses : actions/checkout@v4
57
51
with :
58
52
persist-credentials : false
@@ -63,22 +57,24 @@ jobs:
63
57
node-version : lts/*
64
58
65
59
- name : Install dependencies
66
- run : npm i --ignore-scripts
60
+ run : pnpm i --ignore-scripts
67
61
68
62
- name : Check Licenses
69
- run : ${{ format('npx license-checker --production --summary --onlyAllow="0BSD;Apache-2.0;BlueOak-1.0.0;BSD-2-Clause;BSD-3-Clause;ISC;MIT;{0}"', inputs.license-check-allowed-additional) }}
63
+ run : ${{ format('pnpm dlx license-checker --production --summary --onlyAllow="0BSD;Apache-2.0;BlueOak-1.0.0;BSD-2-Clause;BSD-3-Clause;ISC;MIT;{0}"', inputs.license-check-allowed-additional) }}
70
64
71
65
linter :
72
- needs : [setup_pnpm]
73
66
name : Lint Code
74
67
if : >
75
68
!failure() &&
76
69
!cancelled() &&
77
- inputs.lint == true
78
70
runs-on : ubuntu-latest
79
71
permissions :
80
72
contents : read
81
73
steps :
74
+ - uses : pnpm/action-setup@v4
75
+ with :
76
+ version : 9
77
+
82
78
- name : Check out repo
83
79
uses : actions/checkout@v4
84
80
with :
@@ -96,21 +92,24 @@ jobs:
96
92
run : pnpm lint
97
93
98
94
test :
99
- needs : [setup_pnpm]
100
95
name : Test
101
96
runs-on : ${{ matrix.os }}
102
97
permissions :
103
98
contents : read
104
99
strategy :
105
100
matrix :
106
- node-version : ${{ fromJson(inputs.node-versions ) }}
101
+ node-version : ${{ fromJson('["20", "22"]' ) }}
107
102
os : [macos-latest, ubuntu-latest, windows-latest]
108
103
exclude :
109
104
- os : macos-latest
110
105
node-version : 14
111
106
- os : macos-latest
112
107
node-version : 16
113
108
steps :
109
+ - uses : pnpm/action-setup@v4
110
+ with :
111
+ version : 9
112
+
114
113
- name : Check out repo
115
114
uses : actions/checkout@v4
116
115
with :
@@ -128,16 +127,18 @@ jobs:
128
127
run : pnpm test
129
128
130
129
fastify-dependency-integration :
131
- needs : [setup_pnpm]
132
130
name : Test Fastify Integration
133
131
runs-on : ubuntu-latest
134
132
if : >
135
133
!failure() &&
136
134
!cancelled() &&
137
- inputs.fastify-dependency-integration == true
138
135
permissions :
139
136
contents : read
140
137
steps :
138
+ - uses : pnpm/action-setup@v4
139
+ with :
140
+ version : 9
141
+
141
142
- name : Check out repo
142
143
uses : actions/checkout@v4
143
144
with :
0 commit comments