Skip to content

Commit a8d0000

Browse files
authored
Upgrade deps (#376)
* Upgrade deps * exports * nicer pdas * update * update
1 parent 39012c5 commit a8d0000

File tree

16 files changed

+1499
-1289
lines changed

16 files changed

+1499
-1289
lines changed

.eslintrc.js renamed to .eslintrc.cjs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"use strict";
2+
13
require("@rushstack/eslint-patch/modern-module-resolution");
24

35
module.exports = {

.mocharc.js renamed to .mocharc.cjs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"use strict";
2+
13
require("./.pnp.cjs").setup();
24

35
module.exports = {

.yarn/releases/yarn-3.2.0.cjs

Lines changed: 0 additions & 785 deletions
This file was deleted.

.yarn/releases/yarn-3.2.1.cjs

Lines changed: 786 additions & 0 deletions
Large diffs are not rendered by default.

.yarn/sdks/eslint/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "eslint",
3-
"version": "8.13.0-sdk",
3+
"version": "8.18.0-sdk",
44
"main": "./lib/api.js",
55
"type": "commonjs"
66
}

.yarn/sdks/prettier/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "prettier",
3-
"version": "2.6.2-sdk",
3+
"version": "2.7.1-sdk",
44
"main": "./index.js",
55
"type": "commonjs"
66
}

.yarn/sdks/typescript/lib/tsserver.js

Lines changed: 25 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,18 @@ const moduleWrapper = tsserver => {
6161
//
6262
// Ref: https://github.com/microsoft/vscode/issues/105014#issuecomment-686760910
6363
//
64-
// Update 2021-10-08: VSCode changed their format in 1.61.
64+
// 2021-10-08: VSCode changed the format in 1.61.
6565
// Before | ^zip:/c:/foo/bar.zip/package.json
6666
// After | ^/zip//c:/foo/bar.zip/package.json
6767
//
68-
// Update 2022-04-06: VSCode changed the format in 1.66.
68+
// 2022-04-06: VSCode changed the format in 1.66.
6969
// Before | ^/zip//c:/foo/bar.zip/package.json
7070
// After | ^/zip/c:/foo/bar.zip/package.json
7171
//
72+
// 2022-05-06: VSCode changed the format in 1.68
73+
// Before | ^/zip/c:/foo/bar.zip/package.json
74+
// After | ^/zip//c:/foo/bar.zip/package.json
75+
//
7276
case `vscode <1.61`: {
7377
str = `^zip:${str}`;
7478
} break;
@@ -77,10 +81,14 @@ const moduleWrapper = tsserver => {
7781
str = `^/zip/${str}`;
7882
} break;
7983

80-
case `vscode`: {
84+
case `vscode <1.68`: {
8185
str = `^/zip${str}`;
8286
} break;
8387

88+
case `vscode`: {
89+
str = `^/zip/${str}`;
90+
} break;
91+
8492
// To make "go to definition" work,
8593
// We have to resolve the actual file system path from virtual path
8694
// and convert scheme to supported by [vim-rzip](https://github.com/lbrayner/vim-rzip)
@@ -127,9 +135,7 @@ const moduleWrapper = tsserver => {
127135

128136
case `vscode`:
129137
default: {
130-
return process.platform === `win32`
131-
? str.replace(/^\^?(zip:|\/zip)\/+/, ``)
132-
: str.replace(/^\^?(zip:|\/zip)\/+/, `/`);
138+
return str.replace(/^\^?(zip:|\/zip(\/ts-nul-authority)?)\/+/, process.platform === `win32` ? `` : `/`)
133139
} break;
134140
}
135141
}
@@ -169,10 +175,19 @@ const moduleWrapper = tsserver => {
169175
) {
170176
hostInfo = parsedMessage.arguments.hostInfo;
171177
if (hostInfo === `vscode` && process.env.VSCODE_IPC_HOOK) {
172-
if (/(\/|-)1\.([1-5][0-9]|60)\./.test(process.env.VSCODE_IPC_HOOK)) {
173-
hostInfo += ` <1.61`;
174-
} else if (/(\/|-)1\.(6[1-5])\./.test(process.env.VSCODE_IPC_HOOK)) {
175-
hostInfo += ` <1.66`;
178+
const [, major, minor] = (process.env.VSCODE_IPC_HOOK.match(
179+
// The RegExp from https://semver.org/ but without the caret at the start
180+
/(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$/
181+
) ?? []).map(Number)
182+
183+
if (major === 1) {
184+
if (minor < 61) {
185+
hostInfo += ` <1.61`;
186+
} else if (minor < 66) {
187+
hostInfo += ` <1.66`;
188+
} else if (minor < 68) {
189+
hostInfo += ` <1.68`;
190+
}
176191
}
177192
}
178193
}

.yarn/sdks/typescript/lib/tsserverlibrary.js

Lines changed: 25 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,18 @@ const moduleWrapper = tsserver => {
6161
//
6262
// Ref: https://github.com/microsoft/vscode/issues/105014#issuecomment-686760910
6363
//
64-
// Update 2021-10-08: VSCode changed their format in 1.61.
64+
// 2021-10-08: VSCode changed the format in 1.61.
6565
// Before | ^zip:/c:/foo/bar.zip/package.json
6666
// After | ^/zip//c:/foo/bar.zip/package.json
6767
//
68-
// Update 2022-04-06: VSCode changed the format in 1.66.
68+
// 2022-04-06: VSCode changed the format in 1.66.
6969
// Before | ^/zip//c:/foo/bar.zip/package.json
7070
// After | ^/zip/c:/foo/bar.zip/package.json
7171
//
72+
// 2022-05-06: VSCode changed the format in 1.68
73+
// Before | ^/zip/c:/foo/bar.zip/package.json
74+
// After | ^/zip//c:/foo/bar.zip/package.json
75+
//
7276
case `vscode <1.61`: {
7377
str = `^zip:${str}`;
7478
} break;
@@ -77,10 +81,14 @@ const moduleWrapper = tsserver => {
7781
str = `^/zip/${str}`;
7882
} break;
7983

80-
case `vscode`: {
84+
case `vscode <1.68`: {
8185
str = `^/zip${str}`;
8286
} break;
8387

88+
case `vscode`: {
89+
str = `^/zip/${str}`;
90+
} break;
91+
8492
// To make "go to definition" work,
8593
// We have to resolve the actual file system path from virtual path
8694
// and convert scheme to supported by [vim-rzip](https://github.com/lbrayner/vim-rzip)
@@ -127,9 +135,7 @@ const moduleWrapper = tsserver => {
127135

128136
case `vscode`:
129137
default: {
130-
return process.platform === `win32`
131-
? str.replace(/^\^?(zip:|\/zip)\/+/, ``)
132-
: str.replace(/^\^?(zip:|\/zip)\/+/, `/`);
138+
return str.replace(/^\^?(zip:|\/zip(\/ts-nul-authority)?)\/+/, process.platform === `win32` ? `` : `/`)
133139
} break;
134140
}
135141
}
@@ -169,10 +175,19 @@ const moduleWrapper = tsserver => {
169175
) {
170176
hostInfo = parsedMessage.arguments.hostInfo;
171177
if (hostInfo === `vscode` && process.env.VSCODE_IPC_HOOK) {
172-
if (/(\/|-)1\.([1-5][0-9]|60)\./.test(process.env.VSCODE_IPC_HOOK)) {
173-
hostInfo += ` <1.61`;
174-
} else if (/(\/|-)1\.(6[1-5])\./.test(process.env.VSCODE_IPC_HOOK)) {
175-
hostInfo += ` <1.66`;
178+
const [, major, minor] = (process.env.VSCODE_IPC_HOOK.match(
179+
// The RegExp from https://semver.org/ but without the caret at the start
180+
/(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$/
181+
) ?? []).map(Number)
182+
183+
if (major === 1) {
184+
if (minor < 61) {
185+
hostInfo += ` <1.61`;
186+
} else if (minor < 66) {
187+
hostInfo += ` <1.66`;
188+
} else if (minor < 68) {
189+
hostInfo += ` <1.68`;
190+
}
176191
}
177192
}
178193
}

.yarn/sdks/typescript/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "typescript",
3-
"version": "4.6.3-sdk",
3+
"version": "4.7.4-sdk",
44
"main": "./lib/typescript.js",
55
"type": "commonjs"
66
}

.yarnrc.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ plugins:
66
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
77
spec: "@yarnpkg/plugin-interactive-tools"
88

9-
yarnPath: .yarn/releases/yarn-3.2.0.cjs
9+
yarnPath: .yarn/releases/yarn-3.2.1.cjs

0 commit comments

Comments
 (0)