npm-pkg-lint 3.6.4 → 3.6.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +22 -4
- package/dist/index.js.map +3 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -4335,6 +4335,7 @@ var require_lrucache = __commonJS({
|
|
|
4335
4335
|
// node_modules/semver/classes/range.js
|
|
4336
4336
|
var require_range = __commonJS({
|
|
4337
4337
|
"node_modules/semver/classes/range.js"(exports, module) {
|
|
4338
|
+
var SPACE_CHARACTERS = /\s+/g;
|
|
4338
4339
|
var Range = class _Range {
|
|
4339
4340
|
constructor(range, options) {
|
|
4340
4341
|
options = parseOptions(options);
|
|
@@ -4348,13 +4349,13 @@ var require_range = __commonJS({
|
|
|
4348
4349
|
if (range instanceof Comparator) {
|
|
4349
4350
|
this.raw = range.value;
|
|
4350
4351
|
this.set = [[range]];
|
|
4351
|
-
this.
|
|
4352
|
+
this.formatted = void 0;
|
|
4352
4353
|
return this;
|
|
4353
4354
|
}
|
|
4354
4355
|
this.options = options;
|
|
4355
4356
|
this.loose = !!options.loose;
|
|
4356
4357
|
this.includePrerelease = !!options.includePrerelease;
|
|
4357
|
-
this.raw = range.trim().
|
|
4358
|
+
this.raw = range.trim().replace(SPACE_CHARACTERS, " ");
|
|
4358
4359
|
this.set = this.raw.split("||").map((r) => this.parseRange(r.trim())).filter((c3) => c3.length);
|
|
4359
4360
|
if (!this.set.length) {
|
|
4360
4361
|
throw new TypeError(`Invalid SemVer Range: ${this.raw}`);
|
|
@@ -4373,10 +4374,27 @@ var require_range = __commonJS({
|
|
|
4373
4374
|
}
|
|
4374
4375
|
}
|
|
4375
4376
|
}
|
|
4376
|
-
this.
|
|
4377
|
+
this.formatted = void 0;
|
|
4378
|
+
}
|
|
4379
|
+
get range() {
|
|
4380
|
+
if (this.formatted === void 0) {
|
|
4381
|
+
this.formatted = "";
|
|
4382
|
+
for (let i2 = 0; i2 < this.set.length; i2++) {
|
|
4383
|
+
if (i2 > 0) {
|
|
4384
|
+
this.formatted += "||";
|
|
4385
|
+
}
|
|
4386
|
+
const comps = this.set[i2];
|
|
4387
|
+
for (let k = 0; k < comps.length; k++) {
|
|
4388
|
+
if (k > 0) {
|
|
4389
|
+
this.formatted += " ";
|
|
4390
|
+
}
|
|
4391
|
+
this.formatted += comps[k].toString().trim();
|
|
4392
|
+
}
|
|
4393
|
+
}
|
|
4394
|
+
}
|
|
4395
|
+
return this.formatted;
|
|
4377
4396
|
}
|
|
4378
4397
|
format() {
|
|
4379
|
-
this.range = this.set.map((comps) => comps.join(" ").trim()).join("||").trim();
|
|
4380
4398
|
return this.range;
|
|
4381
4399
|
}
|
|
4382
4400
|
toString() {
|