Skip to content

Commit 18e5312

Browse files
committed
deps: validate-npm-package-name@5.0.1
1 parent d440011 commit 18e5312

File tree

9 files changed

+17
-157
lines changed

9 files changed

+17
-157
lines changed

DEPENDENCIES.md

-2
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,6 @@ graph LR;
266266
bin-links-->read-cmd-shim;
267267
bin-links-->write-file-atomic;
268268
brace-expansion-->balanced-match;
269-
builtins-->semver;
270269
cacache-->fs-minipass;
271270
cacache-->glob;
272271
cacache-->lru-cache;
@@ -777,7 +776,6 @@ graph LR;
777776
unique-slug-->imurmurhash;
778777
validate-npm-package-license-->spdx-correct;
779778
validate-npm-package-license-->spdx-expression-parse;
780-
validate-npm-package-name-->builtins;
781779
which-->isexe;
782780
wrap-ansi-->ansi-styles;
783781
wrap-ansi-->string-width;

node_modules/.gitignore

-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@
5454
!/bin-links
5555
!/binary-extensions
5656
!/brace-expansion
57-
!/builtins
5857
!/cacache
5958
!/chalk
6059
!/chownr

node_modules/builtins/License

-20
This file was deleted.

node_modules/builtins/index.js

-80
This file was deleted.

node_modules/builtins/package.json

-19
This file was deleted.

node_modules/validate-npm-package-name/lib/index.js

+4-6
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
'use strict'
2+
const { builtinModules: builtins } = require('module')
23

34
var scopedPackagePattern = new RegExp('^(?:@([^/]+?)[/])?([^/]+?)$')
4-
var builtins = require('builtins')
55
var blacklist = [
66
'node_modules',
77
'favicon.ico',
@@ -52,11 +52,9 @@ function validate (name) {
5252
// Generate warnings for stuff that used to be allowed
5353

5454
// core module names like http, events, util, etc
55-
builtins({ version: '*' }).forEach(function (builtin) {
56-
if (name.toLowerCase() === builtin) {
57-
warnings.push(builtin + ' is a core module name')
58-
}
59-
})
55+
if (builtins.includes(name.toLowerCase())) {
56+
warnings.push(name + ' is a core module name')
57+
}
6058

6159
if (name.length > 214) {
6260
warnings.push('name can no longer contain more than 214 characters')

node_modules/validate-npm-package-name/package.json

+7-12
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,22 @@
11
{
22
"name": "validate-npm-package-name",
3-
"version": "5.0.0",
3+
"version": "5.0.1",
44
"description": "Give me a string and I'll tell you if it's a valid npm package name",
55
"main": "lib/",
66
"directories": {
77
"test": "test"
88
},
9-
"dependencies": {
10-
"builtins": "^5.0.0"
11-
},
129
"devDependencies": {
13-
"@npmcli/eslint-config": "^3.0.1",
14-
"@npmcli/template-oss": "4.5.1",
10+
"@npmcli/eslint-config": "^4.0.0",
11+
"@npmcli/template-oss": "4.22.0",
1512
"tap": "^16.0.1"
1613
},
1714
"scripts": {
1815
"cov:test": "TAP_FLAGS='--cov' npm run test:code",
1916
"test:code": "tap ${TAP_FLAGS:-'--'} test/*.js",
2017
"test:style": "standard",
2118
"test": "tap",
22-
"lint": "eslint \"**/*.js\"",
19+
"lint": "eslint \"**/*.{js,cjs,ts,mjs,jsx,tsx}\"",
2320
"postlint": "template-oss-check",
2421
"template-oss-apply": "template-oss-apply --force",
2522
"lintfix": "npm run lint -- --fix",
@@ -28,7 +25,7 @@
2825
},
2926
"repository": {
3027
"type": "git",
31-
"url": "https://github.com/npm/validate-npm-package-name.git"
28+
"url": "git+https://github.com/npm/validate-npm-package-name.git"
3229
},
3330
"keywords": [
3431
"npm",
@@ -51,12 +48,10 @@
5148
},
5249
"templateOSS": {
5350
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
54-
"version": "4.5.1"
51+
"version": "4.22.0",
52+
"publish": true
5553
},
5654
"tap": {
57-
"statements": 88,
58-
"branches": 92,
59-
"lines": 88,
6055
"nyc-arg": [
6156
"--exclude",
6257
"tap-snapshots/**"

package-lock.json

+5-16
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@
151151
"text-table": "~0.2.0",
152152
"tiny-relative-date": "^1.3.0",
153153
"treeverse": "^3.0.0",
154-
"validate-npm-package-name": "^5.0.0",
154+
"validate-npm-package-name": "^5.0.1",
155155
"which": "^4.0.0",
156156
"write-file-atomic": "^5.0.1"
157157
},
@@ -2803,15 +2803,6 @@
28032803
"integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==",
28042804
"dev": true
28052805
},
2806-
"node_modules/builtins": {
2807-
"version": "5.1.0",
2808-
"resolved": "https://registry.npmjs.org/builtins/-/builtins-5.1.0.tgz",
2809-
"integrity": "sha512-SW9lzGTLvWTP1AY8xeAMZimqDrIaSdLQUcVr9DMef51niJ022Ri87SwRRKYm4A6iHfkPaiVUu/Duw2Wc4J7kKg==",
2810-
"inBundle": true,
2811-
"dependencies": {
2812-
"semver": "^7.0.0"
2813-
}
2814-
},
28152806
"node_modules/cacache": {
28162807
"version": "18.0.3",
28172808
"resolved": "https://registry.npmjs.org/cacache/-/cacache-18.0.3.tgz",
@@ -14328,13 +14319,11 @@
1432814319
}
1432914320
},
1433014321
"node_modules/validate-npm-package-name": {
14331-
"version": "5.0.0",
14332-
"resolved": "https://registry.npmjs.org/validate-npm-package-name/-/validate-npm-package-name-5.0.0.tgz",
14333-
"integrity": "sha512-YuKoXDAhBYxY7SfOKxHBDoSyENFeW5VvIIQp2TGQuit8gpK6MnWaQelBKxso72DoxTZfZdcP3W90LqpSkgPzLQ==",
14322+
"version": "5.0.1",
14323+
"resolved": "https://registry.npmjs.org/validate-npm-package-name/-/validate-npm-package-name-5.0.1.tgz",
14324+
"integrity": "sha512-OljLrQ9SQdOUqTaQxqL5dEfZWrXExyyWsozYlAWFawPVNuD83igl7uJD2RTkNMbniIYgt8l81eCJGIdQF7avLQ==",
1433414325
"inBundle": true,
14335-
"dependencies": {
14336-
"builtins": "^5.0.0"
14337-
},
14326+
"license": "ISC",
1433814327
"engines": {
1433914328
"node": "^14.17.0 || ^16.13.0 || >=18.0.0"
1434014329
}

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@
116116
"text-table": "~0.2.0",
117117
"tiny-relative-date": "^1.3.0",
118118
"treeverse": "^3.0.0",
119-
"validate-npm-package-name": "^5.0.0",
119+
"validate-npm-package-name": "^5.0.1",
120120
"which": "^4.0.0",
121121
"write-file-atomic": "^5.0.1"
122122
},

0 commit comments

Comments
 (0)