Skip to content

Commit a53ae3e

Browse files
Fixed compilation error
1 parent e91efcf commit a53ae3e

File tree

8 files changed

+19
-16
lines changed

8 files changed

+19
-16
lines changed

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
- uses: actions/checkout@v3
1515
- uses: actions/setup-node@v3
1616
with:
17-
node-version: 18
17+
node-version: 20
1818
registry-url: https://registry.npmjs.org/
1919
- name: Git setup
2020
run: |

lib/node/plugins/transformers/blobs.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ import { Manager } from '../manager.js';
22
export const blobsTransformer = Manager.create()
33
.setKey('blob')
44
.setCompactPatterns([
5-
/\[[\w\d\s`]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/blob\/([\w\d\/.\-_]+)\)/g,
6-
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/blob\/([\w\d\/.\-_]+)/g
5+
/\[[\w\d\s`]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/blob\/([\w\d\/.\-_]+)\/?\)/g,
6+
/(?<!:")(?<=^|\s|>)https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/blob\/([\w\d\/.\-_]+)\/?/g
77
]);
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Manager } from '../manager.js';
22
export const commitTransformer = Manager.create()
33
.setKey('commit')
4+
.setAsCode()
45
.setCompactPatterns([
56
/<a.*href\s?=\s?"?https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/commit\/([\w\d]{40})"?.*>.*<\/a>/g,
67
/\[[\w\d\s`]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/commit\/([\w\d]{40})\)/g,
@@ -9,5 +10,4 @@ export const commitTransformer = Manager.create()
910
])
1011
.setExpandValueReplaces({
1112
2: (value) => value.substring(0, 7)
12-
})
13-
.setAsCode();
13+
});

lib/node/plugins/transformers/compare.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import { Manager } from '../manager.js';
22
export const compareTransformer = Manager.create()
33
.setKey('compare')
44
.setCompactPatterns([
5+
/<a.*href\s?=\s?"?https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/compare\/([\w\d.\-]+)\.{3}([\w\d.\-]+)\/?"?.*>.*<\/a>/g,
56
/\[[\s\w\d`.\-]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/compare\/([\w\d.\-]+)\.{3}([\w\d.\-]+)\)/g,
67
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/compare\/([\w\d.\-]+)\.{3}([\w\d.\-]+)/g,
78
/([\w\d.\-]+)\.{3}([\w\d.\-]+)/g

lib/node/plugins/transformers/pull-request.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ export const pullRequestTransformer = Manager.create()
33
.setKey('pull')
44
.setSplitter('#', true)
55
.setCompactPatterns([
6-
/\[[\s`#@]*\d+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)\)/g,
7-
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)/g,
6+
/<a.*href\s?=\s?"?https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)\/?"?.*>.*<\/a>/g,
7+
/\[[\s`#@]*\d+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)\/?\)/g,
8+
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)\/?/g,
89
/#(\d+)/g
910
]);

lib/node/plugins/transformers/tags.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@ import { Manager } from '../manager.js';
22
export const tagsTransformer = Manager.create()
33
.setKey('tag')
44
.setCompactPatterns([
5-
/\[[\s\w\d`.\-]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)\)/g,
6-
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)/g,
7-
/(?<!:)(?<=^|\s)(v?\d+\.\d+\.\d+-?\w*\.?\d*)(?<!:)/g
5+
/<a.*href\s?=\s?"?https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)\/?"?.*>.*<\/a>/g,
6+
/\[[\s\w\d`.\-]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)\/?\)/g,
7+
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)\/?/g,
8+
/(?<!:)(?<=^|\s|>)(v?\d+\.\d+\.\d+-?\w*\.?\d*)(?<!:)/g
89
])
910
.setExpandFormat('$1/$key/$2', '$1/releases/tag/$2')
1011
.setExpandValueReplaces({

lib/node/plugins/transformers/trees.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ export const treesTransformer = Manager.create()
33
.setKey('tree')
44
.setCompactPatterns([
55
/\[[\s`#@]*\d+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/tree\/([\d\w.\-_\/]+)\)/g,
6-
/(?<!:")(?<=^|\s)https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/tree\/([\d\w.\-_\/]+)/g
6+
/(?<!:")(?<=^|\s|>)https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/tree\/([\d\w.\-_\/]+)/g
77
]);

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"lib/node"
3737
],
3838
"engines": {
39-
"node": ">=18.14"
39+
"node": ">=20.9"
4040
},
4141
"scripts": {
4242
"dev": "vite",
@@ -49,13 +49,13 @@
4949
},
5050
"devDependencies": {
5151
"@babel/plugin-proposal-optional-chaining": "^7.21.0",
52-
"@types/node": "^18.14.1",
52+
"@types/node": "^20.9.2",
5353
"@vuepress/core": "^2.0.0-rc.0",
5454
"@vuepress/utils": "^2.0.0-rc.0",
5555
"bumpp": "^9.0.0",
56-
"rimraf": "^4.1.2",
56+
"rimraf": "^5.0.5",
5757
"tsconfig-vuepress": "^4.0.4",
58-
"typescript": "^4.9.5",
59-
"vite": "^4.5.0"
58+
"typescript": "^5.2.2",
59+
"vite": "^5.0.0"
6060
}
6161
}

0 commit comments

Comments
 (0)