Skip to content

Commit 58c8d9b

Browse files
committed
chore: migrate from get-repository-url to get-pkg to fix axios vulnerability
1 parent 099f8bf commit 58c8d9b

File tree

5 files changed

+53
-99
lines changed

5 files changed

+53
-99
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,10 @@ It can display maps with tiled, raster or vector layers loaded from different so
5151

5252
<!-- auto-generated-peer-dependency-requirements START -->
5353

54-
- **[ol](https://github.com/openlayers/openlayers)**: `^9.0.0`
54+
- **[ol](https://openlayers.org/)**: `^9.0.0`
5555
- **[ol-contextmenu](https://github.com/jonataswalker/ol-contextmenu)**: `^5.4.0`
56-
- **[ol-ext](https://github.com/Viglino/ol-ext)**: `^4.0.15`
57-
- **[vue](https://github.com/vuejs/core)**: `^3.0.0`
56+
- **[ol-ext](https://github.com/Viglino/ol-ext#,)**: `^4.0.15`
57+
- **[vue](https://github.com/vuejs/core/tree/main/packages/vue#readme)**: `^3.0.0`
5858

5959
<!-- auto-generated-peer-dependency-requirements END -->
6060

docs/get-started.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ vue3-openlayers works with the following versions which must be installed as pee
44

55
<!-- auto-generated-peer-dependency-requirements START -->
66

7-
- **[ol](https://github.com/openlayers/openlayers)**: `^9.0.0`
7+
- **[ol](https://openlayers.org/)**: `^9.0.0`
88
- **[ol-contextmenu](https://github.com/jonataswalker/ol-contextmenu)**: `^5.4.0`
9-
- **[ol-ext](https://github.com/Viglino/ol-ext)**: `^4.0.15`
10-
- **[vue](https://github.com/vuejs/core)**: `^3.0.0`
9+
- **[ol-ext](https://github.com/Viglino/ol-ext#,)**: `^4.0.15`
10+
- **[vue](https://github.com/vuejs/core/tree/main/packages/vue#readme)**: `^3.0.0`
1111

1212
<!-- auto-generated-peer-dependency-requirements END -->
1313

package-lock.json

Lines changed: 38 additions & 85 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,11 @@
7979
"@turf/helpers": "^6.5.0",
8080
"file-saver": "^2.0.5",
8181
"jspdf": "^2.5.1",
82-
"proj4": "^2.11.0",
83-
"ol": "^9.1.0",
82+
"ol": "^9.0.0",
8483
"ol-contextmenu": "^5.4.0",
85-
"ol-ext": "^4.0.17",
86-
"vue": "^3.4.21"
84+
"ol-ext": "^4.0.15",
85+
"proj4": "^2.11.0",
86+
"vue": "^3.0.0"
8787
},
8888
"peerDependencies": {
8989
"ol": "^9.0.0",
@@ -114,7 +114,7 @@
114114
"eslint": "^8.57.0",
115115
"eslint-plugin-prettier": "^5.1.3",
116116
"eslint-plugin-vue": "^9.24.0",
117-
"get-repository-url": "^2.0.0",
117+
"get-pkg": "^2.0.0",
118118
"husky": "^9.0.11",
119119
"jsdom": "^24.0.0",
120120
"prettier": "^3.2.5",

scripts/insert-required-versions.mjs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
"use strict";
22

33
import { readFileSync, writeFileSync } from "fs";
4-
import repoUrl from "get-repository-url";
4+
import getPkg from "get-pkg";
55

66
// eslint-disable-next-line no-undef
77
const [, , ...filepaths] = process.argv;
@@ -11,8 +11,9 @@ const config = JSON.parse(packageJson);
1111

1212
Promise.all(
1313
Object.entries(config.peerDependencies).map(async ([depName, depVersion]) => {
14-
const url = await repoUrl(depName);
15-
return `- **[${depName}](${url})**: \`${depVersion}\``;
14+
const packageJson = await getPkg(depName);
15+
console.log(packageJson);
16+
return `- **[${depName}](${packageJson.homepage})**: \`${depVersion}\``;
1617
}),
1718
).then((result) => {
1819
filepaths.forEach((file) => {

0 commit comments

Comments
 (0)