-
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit 5631824
Check/fix problems with npm configuration
The "Check npm" template provides actions and a GitHub Actions workflow used to check for problems with a project's npm
configuration files.
In addition to the `package.json` file previously used, we are now using an `.npmrc` configuration file. It will be
useful to have some validation for this file. npm provides a `config fix` command which automatically fixes any problems
that are detected with the npm configuration. In addition to using it for that purpose, it can also serve as a check by
running the command via the GitHub Actions workflow, then checking for any diff.
Beyond the automated fixes, it is hoped that the parsing of the configuration that npm must perform to check for any
needed fixes provides a basic validation of the configuration. Unfortunately npm's parser is extremely lenient, so the
validation is not at all comprehensive. However, it is probably better than nothing, simple to implement, and no
alternatives were found.1 parent 4f64f22 commit 5631824
3 files changed
+56
-1
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
125 | 125 |
| |
126 | 126 |
| |
127 | 127 |
| |
128 | + | ||
129 | + | ||
130 | + | ||
131 | + | ||
132 | + | ||
133 | + | ||
134 | + | ||
135 | + | ||
136 | + | ||
137 | + | ||
138 | + | ||
139 | + | ||
140 | + | ||
141 | + | ||
142 | + | ||
143 | + | ||
144 | + | ||
145 | + | ||
146 | + | ||
147 | + | ||
148 | + | ||
149 | + | ||
150 | + | ||
151 | + | ||
152 | + | ||
153 | + | ||
154 | + | ||
155 | + | ||
156 | + | ||
157 | + | ||
158 | + | ||
159 | + | ||
160 | + | ||
161 | + | ||
162 | + | ||
163 | + | ||
164 | + | ||
165 | + | ||
166 | + | ||
167 | + | ||
168 | + | ||
169 | + |
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 | 1 |
| |
2 | 2 |
| |
3 | - | ||
3 | + |
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
307 | 307 |
| |
308 | 308 |
| |
309 | 309 |
| |
310 | + | ||
311 | + | ||
312 | + | ||
313 | + | ||
314 | + | ||
315 | + | ||
316 | + | ||
317 | + | ||
318 | + | ||
319 | + | ||
320 | + | ||
321 | + | ||
322 | + | ||
310 | 323 |
| |
311 | 324 |
| |
312 | 325 |
| |
|
0 commit comments