semver 7.7.2 → 7.7.3
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/classes/range.js +1 -0
- package/classes/semver.js +19 -5
- package/internal/identifiers.js +4 -0
- package/package.json +3 -3
package/classes/range.js
CHANGED
|
@@ -255,6 +255,7 @@ const isSatisfiable = (comparators, options) => {
|
|
|
255
255
|
// already replaced the hyphen ranges
|
|
256
256
|
// turn into a set of JUST comparators.
|
|
257
257
|
const parseComparator = (comp, options) => {
|
|
258
|
+
comp = comp.replace(re[t.BUILD], '')
|
|
258
259
|
debug('comp', comp, options)
|
|
259
260
|
comp = replaceCarets(comp, options)
|
|
260
261
|
debug('caret', comp)
|
package/classes/semver.js
CHANGED
|
@@ -111,11 +111,25 @@ class SemVer {
|
|
|
111
111
|
other = new SemVer(other, this.options)
|
|
112
112
|
}
|
|
113
113
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
114
|
+
if (this.major < other.major) {
|
|
115
|
+
return -1
|
|
116
|
+
}
|
|
117
|
+
if (this.major > other.major) {
|
|
118
|
+
return 1
|
|
119
|
+
}
|
|
120
|
+
if (this.minor < other.minor) {
|
|
121
|
+
return -1
|
|
122
|
+
}
|
|
123
|
+
if (this.minor > other.minor) {
|
|
124
|
+
return 1
|
|
125
|
+
}
|
|
126
|
+
if (this.patch < other.patch) {
|
|
127
|
+
return -1
|
|
128
|
+
}
|
|
129
|
+
if (this.patch > other.patch) {
|
|
130
|
+
return 1
|
|
131
|
+
}
|
|
132
|
+
return 0
|
|
119
133
|
}
|
|
120
134
|
|
|
121
135
|
comparePre (other) {
|
package/internal/identifiers.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "semver",
|
|
3
|
-
"version": "7.7.
|
|
3
|
+
"version": "7.7.3",
|
|
4
4
|
"description": "The semantic version parser used by npm.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
},
|
|
16
16
|
"devDependencies": {
|
|
17
17
|
"@npmcli/eslint-config": "^5.0.0",
|
|
18
|
-
"@npmcli/template-oss": "4.
|
|
18
|
+
"@npmcli/template-oss": "4.25.1",
|
|
19
19
|
"benchmark": "^2.1.4",
|
|
20
20
|
"tap": "^16.0.0"
|
|
21
21
|
},
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"author": "GitHub Inc.",
|
|
53
53
|
"templateOSS": {
|
|
54
54
|
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
|
|
55
|
-
"version": "4.
|
|
55
|
+
"version": "4.25.1",
|
|
56
56
|
"engines": ">=10",
|
|
57
57
|
"distPaths": [
|
|
58
58
|
"classes/",
|