Skip to content

Commit

Permalink
Fixed compilation error
Browse files Browse the repository at this point in the history
  • Loading branch information
andrey-helldar committed Nov 19, 2023
1 parent e91efcf commit a53ae3e
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 16 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
node-version: 20
registry-url: https://registry.npmjs.org/
- name: Git setup
run: |
Expand Down
4 changes: 2 additions & 2 deletions lib/node/plugins/transformers/blobs.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ import { Manager } from '../manager.js';
export const blobsTransformer = Manager.create()
.setKey('blob')
.setCompactPatterns([
/\[[\w\d\s`]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/blob\/([\w\d\/.\-_]+)\)/g,
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/blob\/([\w\d\/.\-_]+)/g
/\[[\w\d\s`]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/blob\/([\w\d\/.\-_]+)\/?\)/g,
/(?<!:")(?<=^|\s|>)https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/blob\/([\w\d\/.\-_]+)\/?/g
]);
4 changes: 2 additions & 2 deletions lib/node/plugins/transformers/commit.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { Manager } from '../manager.js';
export const commitTransformer = Manager.create()
.setKey('commit')
.setAsCode()
.setCompactPatterns([
/<a.*href\s?=\s?"?https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/commit\/([\w\d]{40})"?.*>.*<\/a>/g,
/\[[\w\d\s`]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/commit\/([\w\d]{40})\)/g,
Expand All @@ -9,5 +10,4 @@ export const commitTransformer = Manager.create()
])
.setExpandValueReplaces({
2: (value) => value.substring(0, 7)
})
.setAsCode();
});
1 change: 1 addition & 0 deletions lib/node/plugins/transformers/compare.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { Manager } from '../manager.js';
export const compareTransformer = Manager.create()
.setKey('compare')
.setCompactPatterns([
/<a.*href\s?=\s?"?https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/compare\/([\w\d.\-]+)\.{3}([\w\d.\-]+)\/?"?.*>.*<\/a>/g,
/\[[\s\w\d`.\-]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/compare\/([\w\d.\-]+)\.{3}([\w\d.\-]+)\)/g,
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/compare\/([\w\d.\-]+)\.{3}([\w\d.\-]+)/g,
/([\w\d.\-]+)\.{3}([\w\d.\-]+)/g
Expand Down
5 changes: 3 additions & 2 deletions lib/node/plugins/transformers/pull-request.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ export const pullRequestTransformer = Manager.create()
.setKey('pull')
.setSplitter('#', true)
.setCompactPatterns([
/\[[\s`#@]*\d+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)\)/g,
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)/g,
/<a.*href\s?=\s?"?https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)\/?"?.*>.*<\/a>/g,
/\[[\s`#@]*\d+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)\/?\)/g,
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/pull\/(\d+)\/?/g,
/#(\d+)/g
]);
7 changes: 4 additions & 3 deletions lib/node/plugins/transformers/tags.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ import { Manager } from '../manager.js';
export const tagsTransformer = Manager.create()
.setKey('tag')
.setCompactPatterns([
/\[[\s\w\d`.\-]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)\)/g,
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)/g,
/(?<!:)(?<=^|\s)(v?\d+\.\d+\.\d+-?\w*\.?\d*)(?<!:)/g
/<a.*href\s?=\s?"?https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)\/?"?.*>.*<\/a>/g,
/\[[\s\w\d`.\-]+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)\/?\)/g,
/https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/releases\/tag\/(v?\d+\.\d+\.\d+-?\w*\.?\d*)\/?/g,
/(?<!:)(?<=^|\s|>)(v?\d+\.\d+\.\d+-?\w*\.?\d*)(?<!:)/g
])
.setExpandFormat('$1/$key/$2', '$1/releases/tag/$2')
.setExpandValueReplaces({
Expand Down
2 changes: 1 addition & 1 deletion lib/node/plugins/transformers/trees.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ export const treesTransformer = Manager.create()
.setKey('tree')
.setCompactPatterns([
/\[[\s`#@]*\d+]\(https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/tree\/([\d\w.\-_\/]+)\)/g,
/(?<!:")(?<=^|\s)https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/tree\/([\d\w.\-_\/]+)/g
/(?<!:")(?<=^|\s|>)https:\/\/github\.com\/([\w\d\-_]+)\/([\w\d\-_]+)\/tree\/([\d\w.\-_\/]+)/g
]);
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"lib/node"
],
"engines": {
"node": ">=18.14"
"node": ">=20.9"
},
"scripts": {
"dev": "vite",
Expand All @@ -49,13 +49,13 @@
},
"devDependencies": {
"@babel/plugin-proposal-optional-chaining": "^7.21.0",
"@types/node": "^18.14.1",
"@types/node": "^20.9.2",
"@vuepress/core": "^2.0.0-rc.0",
"@vuepress/utils": "^2.0.0-rc.0",
"bumpp": "^9.0.0",
"rimraf": "^4.1.2",
"rimraf": "^5.0.5",
"tsconfig-vuepress": "^4.0.4",
"typescript": "^4.9.5",
"vite": "^4.5.0"
"typescript": "^5.2.2",
"vite": "^5.0.0"
}
}

0 comments on commit a53ae3e

Please sign in to comment.