diff --git a/package-lock.json b/package-lock.json index 5669d9d..f9599c8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -262,9 +262,9 @@ "dev": true }, "@types/vscode": { - "version": "1.60.0", - "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.60.0.tgz", - "integrity": "sha512-wZt3VTmzYrgZ0l/3QmEbCq4KAJ71K3/hmMQ/nfpv84oH8e81KKwPEoQ5v8dNCxfHFVJ1JabHKmCvqdYOoVm1Ow==", + "version": "1.63.0", + "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.63.0.tgz", + "integrity": "sha512-iePu1axOi5WSThV6l2TYcciBIpAlMarjBC8H0y8L8ocsZLxh7MttzwFU3pjoItF5fRVGxHS0Hsvje9jO3yJsfw==", "dev": true }, "@ungap/promise-all-settled": { @@ -2118,9 +2118,9 @@ } }, "minimist": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", + "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==", "dev": true }, "mkdirp-classic": { diff --git a/package.json b/package.json index 669fb39..a888208 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "explorer" ], "engines": { - "vscode": "^1.60.0" + "vscode": "^1.63.0" }, "repository": { "type": "git", @@ -622,7 +622,7 @@ "@types/mocha": "^9.1.0", "@types/node": "^14.14.0", "@types/semver": "^7.3.9", - "@types/vscode": "1.60.0", + "@types/vscode": "1.63.0", "copy-webpack-plugin": "^9.1.0", "glob": "^7.2.0", "mocha": "^9.2.2", diff --git a/scripts/prepare-nightly-build.js b/scripts/prepare-nightly-build.js new file mode 100644 index 0000000..7e40038 --- /dev/null +++ b/scripts/prepare-nightly-build.js @@ -0,0 +1,25 @@ +const fs = require("fs"); + +const json = JSON.parse(fs.readFileSync("./package.json").toString()); +const stableVersion = json.version.match(/(\d+)\.(\d+)\.(\d+)/); +const major = stableVersion[1]; +const minor = stableVersion[2]; + +function prependZero(number) { + if (number > 99) { + throw "Unexpected value to prepend with zero"; + } + return `${number < 10 ? "0" : ""}${number}`; +} + +const date = new Date(); +const month = date.getMonth() + 1; +const day = date.getDate(); +const hours = date.getHours(); +patch = `${date.getFullYear()}${prependZero(month)}${prependZero(day)}${prependZero(hours)}`; + +const insiderPackageJson = Object.assign(json, { + version: `${major}.${minor}.${patch}`, +}); + +fs.writeFileSync("./package.insiders.json", JSON.stringify(insiderPackageJson)); \ No newline at end of file diff --git a/src/explorerCommands/utility.ts b/src/explorerCommands/utility.ts index 22e2696..3b46bcb 100644 --- a/src/explorerCommands/utility.ts +++ b/src/explorerCommands/utility.ts @@ -35,7 +35,7 @@ export function checkJavaQualifiedName(value: string): string { return ""; } -export function getCmdNode(selectedNodes: ExplorerNode[], node?: DataNode): DataNode | undefined { +export function getCmdNode(selectedNodes: readonly ExplorerNode[], node?: DataNode): DataNode | undefined { // if command not invoked by context menu, use selected node in explorer if (node) { return node;