diff --git a/CHANGELOG.md b/CHANGELOG.md
index 597d248..ff4ebaf 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,12 @@
+## version 1.1.9
+- BWC90 & WC317 数据
+
+## version 1.1.8
+- WC316 数据
+
+## version 1.1.7
+- Windows环境使用VsCode自带node环境,测试用例解析问题
+
## version 1.1.6
- 尝试不需要安装node环境
diff --git a/README.md b/README.md
index 481017b..1c56567 100644
--- a/README.md
+++ b/README.md
@@ -70,6 +70,7 @@
| leetcode-problem-rating.pickOneByRankRangeMin | 随机一题的最小浮动,随机一题最低分(你的竞赛分+本配置)。 | 50 |
| leetcode-problem-rating.pickOneByRankRangeMax | 随机一题的最大浮动,随机一题最高分(你的竞赛分+本配置)。 | 150 |
| leetcode-problem-rating.hideScore | 隐藏分数相关的题目。Score:隐藏有分数的题目, NoScore:隐藏没有分数的题目, ScoreRange:隐藏分数范围外的题目 | None |
+| leetcode-problem-rating.useVscodeNode | 默认情况下使用VsCode自带Node环境,不需要额外安装Node环境 | true |
diff --git a/package-lock.json b/package-lock.json
index 4cfb038..888f16e 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "vscode-leetcode-problem-rating",
- "version": "1.1.6",
+ "version": "1.1.8",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "vscode-leetcode-problem-rating",
- "version": "1.1.6",
+ "version": "1.1.8",
"license": "MIT",
"dependencies": {
"ansi-styles": "3.2.1",
@@ -101,9 +101,9 @@
"dev": true
},
"node_modules/@types/lodash": {
- "version": "4.14.186",
- "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.186.tgz",
- "integrity": "sha512-eHcVlLXP0c2FlMPm56ITode2AgLMSa6aJ05JTTbYbI+7EMkCEE5qk2E41d5g2lCVTqRe0GnnRFurmlCsDODrPw==",
+ "version": "4.14.188",
+ "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.188.tgz",
+ "integrity": "sha512-zmEmF5OIM3rb7SbLCFYoQhO4dGt2FRM9AMkxvA3LaADOF1n8in/zGJlWji9fmafLoNyz+FoL6FE0SLtGIArD7w==",
"dev": true
},
"node_modules/@types/markdown-it": {
@@ -116,9 +116,9 @@
}
},
"node_modules/@types/node": {
- "version": "14.18.32",
- "resolved": "https://registry.npmjs.org/@types/node/-/node-14.18.32.tgz",
- "integrity": "sha512-Y6S38pFr04yb13qqHf8uk1nHE3lXgQ30WZbv1mLliV9pt0NjvqdWttLcrOYLnXbOafknVYRHZGoMSpR9UwfYow==",
+ "version": "14.18.33",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-14.18.33.tgz",
+ "integrity": "sha512-qelS/Ra6sacc4loe/3MSjXNL1dNQ/GjxNHVzuChwMfmk7HuycRLVQN2qNY3XahK+fZc5E2szqQSKUyAF0E+2bg==",
"dev": true
},
"node_modules/@types/require-from-string": {
@@ -874,9 +874,9 @@
}
},
"node_modules/is-core-module": {
- "version": "2.10.0",
- "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.10.0.tgz",
- "integrity": "sha512-Erxj2n/LDAZ7H8WNJXd9tw38GYM3dv8rk8Zcs+jJuxYTW7sozH+SS8NtrSjVL1/vpLvWi1hxy96IzjJ3EHTJJg==",
+ "version": "2.11.0",
+ "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.11.0.tgz",
+ "integrity": "sha512-RRjxlvLDkD1YJwDbroBHMb+cukurkDWNyHx7D3oNB5x9rb5ogcksMC5wHCadcXoo67gVr/+3GFySh3134zi6rw==",
"dev": true,
"dependencies": {
"has": "^1.0.3"
@@ -1867,9 +1867,9 @@
"dev": true
},
"@types/lodash": {
- "version": "4.14.186",
- "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.186.tgz",
- "integrity": "sha512-eHcVlLXP0c2FlMPm56ITode2AgLMSa6aJ05JTTbYbI+7EMkCEE5qk2E41d5g2lCVTqRe0GnnRFurmlCsDODrPw==",
+ "version": "4.14.188",
+ "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.188.tgz",
+ "integrity": "sha512-zmEmF5OIM3rb7SbLCFYoQhO4dGt2FRM9AMkxvA3LaADOF1n8in/zGJlWji9fmafLoNyz+FoL6FE0SLtGIArD7w==",
"dev": true
},
"@types/markdown-it": {
@@ -1882,9 +1882,9 @@
}
},
"@types/node": {
- "version": "14.18.32",
- "resolved": "https://registry.npmjs.org/@types/node/-/node-14.18.32.tgz",
- "integrity": "sha512-Y6S38pFr04yb13qqHf8uk1nHE3lXgQ30WZbv1mLliV9pt0NjvqdWttLcrOYLnXbOafknVYRHZGoMSpR9UwfYow==",
+ "version": "14.18.33",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-14.18.33.tgz",
+ "integrity": "sha512-qelS/Ra6sacc4loe/3MSjXNL1dNQ/GjxNHVzuChwMfmk7HuycRLVQN2qNY3XahK+fZc5E2szqQSKUyAF0E+2bg==",
"dev": true
},
"@types/require-from-string": {
@@ -2457,9 +2457,9 @@
"integrity": "sha512-7PnF4oN3CvZF23ADhA5wRaYEQpJ8qygSkbtTXWBeXWXmEVRXK+1ITciHWwHhsjv1TmW0MgacIv6hEi5pX5NQdA=="
},
"is-core-module": {
- "version": "2.10.0",
- "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.10.0.tgz",
- "integrity": "sha512-Erxj2n/LDAZ7H8WNJXd9tw38GYM3dv8rk8Zcs+jJuxYTW7sozH+SS8NtrSjVL1/vpLvWi1hxy96IzjJ3EHTJJg==",
+ "version": "2.11.0",
+ "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.11.0.tgz",
+ "integrity": "sha512-RRjxlvLDkD1YJwDbroBHMb+cukurkDWNyHx7D3oNB5x9rb5ogcksMC5wHCadcXoo67gVr/+3GFySh3134zi6rw==",
"dev": true,
"requires": {
"has": "^1.0.3"
diff --git a/package.json b/package.json
index 91a5e1d..488a488 100644
--- a/package.json
+++ b/package.json
@@ -2,7 +2,7 @@
"name": "vscode-leetcode-problem-rating",
"displayName": "LeetCode problem rating",
"description": "为LeetCode题目难度进行打分。避免只有简单、中等、困难三种难度",
- "version": "1.1.6",
+ "version": "1.1.9",
"author": "ccagml",
"publisher": "ccagml",
"license": "MIT",
diff --git a/resources/data.json b/resources/data.json
index 5b499da..fcea40c 100644
--- a/resources/data.json
+++ b/resources/data.json
@@ -1286,6 +1286,17 @@
"ContestID_en": "Weekly Contest 220",
"ContestID_zh": "\u7b2c 220 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 2298.6242048519,
+ "ID": 2458,
+ "Title": "Height of Binary Tree After Subtree Removal Queries",
+ "TitleZH": "\u79fb\u9664\u5b50\u6811\u540e\u7684\u4e8c\u53c9\u6811\u9ad8\u5ea6",
+ "TitleSlug": "height-of-binary-tree-after-subtree-removal-queries",
+ "ContestSlug": "weekly-contest-317",
+ "ProblemIndex": "Q4",
+ "ContestID_en": "Weekly Contest 317",
+ "ContestID_zh": "\u7b2c 317 \u573a\u5468\u8d5b"
+ },
{
"Rating": 2297.105362516,
"ID": 1263,
@@ -1957,6 +1968,17 @@
"ContestID_en": "Weekly Contest 185",
"ContestID_zh": "\u7b2c 185 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 2175.1190473433,
+ "ID": 2454,
+ "Title": "Next Greater Element IV",
+ "TitleZH": "\u4e0b\u4e00\u4e2a\u66f4\u5927\u5143\u7d20 IV",
+ "TitleSlug": "next-greater-element-iv",
+ "ContestSlug": "biweekly-contest-90",
+ "ProblemIndex": "Q4",
+ "ContestID_en": "Biweekly Contest 90",
+ "ContestID_zh": "\u7b2c 90 \u573a\u53cc\u5468\u8d5b"
+ },
{
"Rating": 2171.716066664,
"ID": 1691,
@@ -2705,6 +2727,17 @@
"ContestID_en": "Biweekly Contest 2",
"ContestID_zh": "\u7b2c 2 \u573a\u53cc\u5468\u8d5b"
},
+ {
+ "Rating": 2076.0155978787,
+ "ID": 2449,
+ "Title": "Minimum Number of Operations to Make Arrays Similar",
+ "TitleZH": "\u4f7f\u6570\u7ec4\u76f8\u4f3c\u7684\u6700\u5c11\u64cd\u4f5c\u6b21\u6570",
+ "TitleSlug": "minimum-number-of-operations-to-make-arrays-similar",
+ "ContestSlug": "weekly-contest-316",
+ "ProblemIndex": "Q4",
+ "ContestID_en": "Weekly Contest 316",
+ "ContestID_zh": "\u7b2c 316 \u573a\u5468\u8d5b"
+ },
{
"Rating": 2075.9046975409,
"ID": 2354,
@@ -3354,6 +3387,17 @@
"ContestID_en": "Weekly Contest 244",
"ContestID_zh": "\u7b2c 244 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 2005.3737929084,
+ "ID": 2448,
+ "Title": "Minimum Cost to Make Array Equal",
+ "TitleZH": "\u4f7f\u6570\u7ec4\u76f8\u7b49\u7684\u6700\u5c0f\u5f00\u9500",
+ "TitleSlug": "minimum-cost-to-make-array-equal",
+ "ContestSlug": "weekly-contest-316",
+ "ProblemIndex": "Q3",
+ "ContestID_en": "Weekly Contest 316",
+ "ContestID_zh": "\u7b2c 316 \u573a\u5468\u8d5b"
+ },
{
"Rating": 2005.2755755378,
"ID": 1761,
@@ -5906,6 +5950,17 @@
"ContestID_en": "Weekly Contest 163",
"ContestID_zh": "\u7b2c 163 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 1761.9162628125,
+ "ID": 2453,
+ "Title": "Destroy Sequential Targets",
+ "TitleZH": "\u6467\u6bc1\u4e00\u7cfb\u5217\u76ee\u6807",
+ "TitleSlug": "destroy-sequential-targets",
+ "ContestSlug": "biweekly-contest-90",
+ "ProblemIndex": "Q3",
+ "ContestID_en": "Biweekly Contest 90",
+ "ContestID_zh": "\u7b2c 90 \u573a\u53cc\u5468\u8d5b"
+ },
{
"Rating": 1760.9131492436,
"ID": 2121,
@@ -6907,6 +6962,17 @@
"ContestID_en": "Weekly Contest 281",
"ContestID_zh": "\u7b2c 281 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 1680.0815931601,
+ "ID": 2457,
+ "Title": "Minimum Addition to Make Integer Beautiful",
+ "TitleZH": "\u7f8e\u4e3d\u6574\u6570\u7684\u6700\u5c0f\u589e\u91cf",
+ "TitleSlug": "minimum-addition-to-make-integer-beautiful",
+ "ContestSlug": "weekly-contest-317",
+ "ProblemIndex": "Q3",
+ "ContestID_en": "Weekly Contest 317",
+ "ContestID_zh": "\u7b2c 317 \u573a\u5468\u8d5b"
+ },
{
"Rating": 1679.2607152001,
"ID": 1402,
@@ -7908,6 +7974,17 @@
"ContestID_en": "Biweekly Contest 81",
"ContestID_zh": "\u7b2c 81 \u573a\u53cc\u5468\u8d5b"
},
+ {
+ "Rating": 1602.7742849665,
+ "ID": 2447,
+ "Title": "Number of Subarrays With GCD Equal to K",
+ "TitleZH": "\u6700\u5927\u516c\u56e0\u6570\u7b49\u4e8e K \u7684\u5b50\u6570\u7ec4\u6570\u76ee",
+ "TitleSlug": "number-of-subarrays-with-gcd-equal-to-k",
+ "ContestSlug": "weekly-contest-316",
+ "ProblemIndex": "Q2",
+ "ContestID_en": "Weekly Contest 316",
+ "ContestID_zh": "\u7b2c 316 \u573a\u5468\u8d5b"
+ },
{
"Rating": 1602.7242171967,
"ID": 2249,
@@ -8480,6 +8557,17 @@
"ContestID_en": "Biweekly Contest 18",
"ContestID_zh": "\u7b2c 18 \u573a\u53cc\u5468\u8d5b"
},
+ {
+ "Rating": 1548.1751146981,
+ "ID": 2456,
+ "Title": "Most Popular Video Creator",
+ "TitleZH": "\u6700\u6d41\u884c\u7684\u89c6\u9891\u521b\u4f5c\u8005",
+ "TitleSlug": "most-popular-video-creator",
+ "ContestSlug": "weekly-contest-317",
+ "ProblemIndex": "Q2",
+ "ContestID_en": "Weekly Contest 317",
+ "ContestID_zh": "\u7b2c 317 \u573a\u5468\u8d5b"
+ },
{
"Rating": 1548.0854419238,
"ID": 1599,
@@ -9690,6 +9778,17 @@
"ContestID_en": "Weekly Contest 170",
"ContestID_zh": "\u7b2c 170 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 1459.7513584849,
+ "ID": 2452,
+ "Title": "Words Within Two Edits of Dictionary",
+ "TitleZH": "\u8ddd\u79bb\u5b57\u5178\u4e24\u6b21\u7f16\u8f91\u4ee5\u5185\u7684\u5355\u8bcd",
+ "TitleSlug": "words-within-two-edits-of-dictionary",
+ "ContestSlug": "biweekly-contest-90",
+ "ProblemIndex": "Q2",
+ "ContestID_en": "Biweekly Contest 90",
+ "ContestID_zh": "\u7b2c 90 \u573a\u53cc\u5468\u8d5b"
+ },
{
"Rating": 1458.356493039,
"ID": 2062,
@@ -10482,6 +10581,17 @@
"ContestID_en": "Weekly Contest 244",
"ContestID_zh": "\u7b2c 244 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 1406.1279714442,
+ "ID": 2451,
+ "Title": "Odd String Difference",
+ "TitleZH": "\u5dee\u503c\u6570\u7ec4\u4e0d\u540c\u7684\u5b57\u7b26\u4e32",
+ "TitleSlug": "odd-string-difference",
+ "ContestSlug": "biweekly-contest-90",
+ "ProblemIndex": "Q1",
+ "ContestID_en": "Biweekly Contest 90",
+ "ContestID_zh": "\u7b2c 90 \u573a\u53cc\u5468\u8d5b"
+ },
{
"Rating": 1405.5786892723,
"ID": 1561,
@@ -11956,6 +12066,17 @@
"ContestID_en": "Weekly Contest 250",
"ContestID_zh": "\u7b2c 250 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 1322.3886921778,
+ "ID": 2446,
+ "Title": "Determine if Two Events Have Conflict",
+ "TitleZH": "\u5224\u65ad\u4e24\u4e2a\u4e8b\u4ef6\u662f\u5426\u5b58\u5728\u51b2\u7a81",
+ "TitleSlug": "determine-if-two-events-have-conflict",
+ "ContestSlug": "weekly-contest-316",
+ "ProblemIndex": "Q1",
+ "ContestID_en": "Weekly Contest 316",
+ "ContestID_zh": "\u7b2c 316 \u573a\u5468\u8d5b"
+ },
{
"Rating": 1321.9346201204,
"ID": 1694,
@@ -14893,6 +15014,17 @@
"ContestID_en": "Weekly Contest 167",
"ContestID_zh": "\u7b2c 167 \u573a\u5468\u8d5b"
},
+ {
+ "Rating": 1151.2537511408,
+ "ID": 2455,
+ "Title": "Average Value of Even Numbers That Are Divisible by Three",
+ "TitleZH": "\u53ef\u88ab\u4e09\u6574\u9664\u7684\u5076\u6570\u7684\u5e73\u5747\u503c",
+ "TitleSlug": "average-value-of-even-numbers-that-are-divisible-by-three",
+ "ContestSlug": "weekly-contest-317",
+ "ProblemIndex": "Q1",
+ "ContestID_en": "Weekly Contest 317",
+ "ContestID_zh": "\u7b2c 317 \u573a\u5468\u8d5b"
+ },
{
"Rating": 1144.9508874557,
"ID": 2413,
diff --git a/src/commands/test.ts b/src/commands/test.ts
index cb0be6b..7b0c18e 100644
--- a/src/commands/test.ts
+++ b/src/commands/test.ts
@@ -130,9 +130,15 @@ function parseTestString(test: string): string {
// In windows and not using WSL
if (usingCmd()) {
+ // 一般需要走进这里, 除非改了 环境变量ComSpec的值
+ if (wsl.useVscodeNode()) {
+ return `${test.replace(/"/g, '\"')}`;
+ }
return `"${test.replace(/"/g, '\\"')}"`;
} else {
- // Assume using PowerShell
+ if (wsl.useVscodeNode()) {
+ return `${test.replace(/"/g, '\"')}`;
+ }
return `'${test.replace(/"/g, '\\"')}'`;
}
}