Skip to content

Commit a5407d8

Browse files
authored
update dependencies (#633)
* update dependencies Signed-off-by: Yan Zhang <[email protected]> * fix tslint Signed-off-by: Yan Zhang <[email protected]>
1 parent 7bc4c86 commit a5407d8

File tree

10 files changed

+1346
-3287
lines changed

10 files changed

+1346
-3287
lines changed

gulpfile.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const server_dir = '../java-debug';
99

1010
gulp.task("tslint", () => {
1111
return gulp.src(["**/*.ts", "!**/*.d.ts", "!node_modules/**", "!./src/views/node_modules/**"])
12-
.pipe(tslint())
12+
.pipe(tslint({formatter: "verbose"}))
1313
.pipe(tslint.report());
1414
});
1515

package-lock.json

Lines changed: 1306 additions & 3252 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -526,24 +526,24 @@
526526
"test": "npm run compile && node ./out/test/index.js"
527527
},
528528
"devDependencies": {
529-
"@types/lodash": "^4.14.116",
530-
"@types/mocha": "^5.2.5",
531-
"@types/node": "^8.10.22",
532-
"@types/vscode": "^1.32.0",
529+
"@types/lodash": "^4.14.137",
530+
"@types/mocha": "^5.2.7",
531+
"@types/node": "^8.10.51",
532+
"@types/vscode": "1.32.0",
533533
"cross-env": "^5.2.0",
534-
"gulp": "^4.0.0",
535-
"gulp-tslint": "^8.1.2",
534+
"gulp": "^4.0.2",
535+
"gulp-tslint": "^8.1.4",
536536
"mocha": "^5.2.0",
537-
"shelljs": "^0.8.2",
538-
"ts-loader": "^5.3.3",
539-
"tslint": "^5.7.0",
540-
"typescript": "^3.0.1",
541-
"vscode-test": "^1.0.2",
542-
"webpack": "^4.29.3",
543-
"webpack-cli": "^3.2.3"
537+
"shelljs": "^0.8.3",
538+
"ts-loader": "^5.4.5",
539+
"tslint": "^5.18.0",
540+
"typescript": "^3.5.3",
541+
"vscode-test": "^1.2.0",
542+
"webpack": "^4.39.2",
543+
"webpack-cli": "^3.3.7"
544544
},
545545
"dependencies": {
546-
"lodash": "^4.17.13",
546+
"lodash": "^4.17.15",
547547
"vscode-extension-telemetry": "0.1.1",
548548
"vscode-extension-telemetry-wrapper": "0.4.0"
549549
}

src/configurationProvider.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,7 @@ export class JavaDebugConfigurationProvider implements vscode.DebugConfiguration
247247
return config;
248248
} else {
249249
// Information for diagnostic:
250+
// tslint:disable-next-line:no-console
250251
console.log("Cannot find a port for debugging session");
251252
throw new Error("Failed to start debug server.");
252253
}
@@ -302,21 +303,21 @@ export class JavaDebugConfigurationProvider implements vscode.DebugConfiguration
302303
if (mainEntries.length === 1) {
303304
return mainEntries[0];
304305
} else if (mainEntries.length > 1) {
305-
return await this.showMainClassQuickPick(this.formatMainClassOptions(mainEntries),
306+
return this.showMainClassQuickPick(this.formatMainClassOptions(mainEntries),
306307
`Multiple main classes found in the file '${path.basename(currentFile)}', please select one first.`);
307308
}
308309
}
309310

310311
const hintMessage = currentFile ?
311312
`No main class found in the file '${path.basename(currentFile)}', please select main class<project name> again.` :
312313
"Please select main class<project name>.";
313-
return await this.promptMainClass(folder, hintMessage);
314+
return this.promptMainClass(folder, hintMessage);
314315
}
315316

316317
const containsExternalClasspaths = !_.isEmpty(config.classPaths) || !_.isEmpty(config.modulePaths);
317318
const validationResponse = await lsPlugin.validateLaunchConfig(folder, config.mainClass, config.projectName, containsExternalClasspaths);
318319
if (!validationResponse.mainClass.isValid || !validationResponse.projectName.isValid) {
319-
return await this.fixMainClass(folder, config, validationResponse);
320+
return this.fixMainClass(folder, config, validationResponse);
320321
}
321322

322323
return {
@@ -504,11 +505,13 @@ async function updateDebugSettings() {
504505
const javaHome = await utility.getJavaHome();
505506
if (debugSettingsRoot.settings && Object.keys(debugSettingsRoot.settings).length) {
506507
try {
508+
// tslint:disable-next-line:no-console
507509
console.log("settings:", await commands.executeJavaLanguageServerCommand(commands.JAVA_UPDATE_DEBUG_SETTINGS, JSON.stringify(
508510
{ ...debugSettingsRoot.settings, logLevel, javaHome })));
509511
} catch (err) {
510512
// log a warning message and continue, since update settings failure should not block debug session
511-
console.log("Cannot update debug settings.", err)
513+
// tslint:disable-next-line:no-console
514+
console.log("Cannot update debug settings.", err);
512515
}
513516
}
514517
}

src/debugCodeLensProvider.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class DebugCodeLensContainer implements vscode.Disposable {
4343
this.runCommand = instrumentOperationAsVsCodeCommand(JAVA_RUN_CODELENS_COMMAND, runJavaProgram);
4444
this.debugCommand = instrumentOperationAsVsCodeCommand(JAVA_DEBUG_CODELENS_COMMAND, debugJavaProgram);
4545

46-
const configuration = vscode.workspace.getConfiguration(JAVA_DEBUG_CONFIGURATION)
46+
const configuration = vscode.workspace.getConfiguration(JAVA_DEBUG_CONFIGURATION);
4747
const isCodeLensEnabled = configuration.get<boolean>(ENABLE_CODE_LENS_VARIABLE);
4848

4949
if (isCodeLensEnabled) {

src/extension.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { dispose as disposeTelemetryWrapper, initializeFromJsonFile, instrumentO
77
import * as commands from "./commands";
88
import { JavaDebugConfigurationProvider } from "./configurationProvider";
99
import { HCR_EVENT, JAVA_LANGID, USER_NOTIFICATION_EVENT } from "./constants";
10-
import { initializeCodeLensProvider, startDebugging } from "./debugCodeLensProvider"
10+
import { initializeCodeLensProvider, startDebugging } from "./debugCodeLensProvider";
1111
import { handleHotCodeReplaceCustomEvent, initializeHotCodeReplace } from "./hotCodeReplace";
1212
import { IMainMethod, resolveMainMethod } from "./languageServerPlugin";
1313
import { logger, Type } from "./logger";
@@ -135,7 +135,7 @@ async function applyHCR() {
135135
await autobuildConfig.update("enabled", true);
136136
// Force an incremental build to avoid auto build is not finishing during HCR.
137137
try {
138-
await commands.executeJavaExtensionCommand(commands.JAVA_BUILD_WORKSPACE, false)
138+
await commands.executeJavaExtensionCommand(commands.JAVA_BUILD_WORKSPACE, false);
139139
} catch (err) {
140140
// do nothing.
141141
}

src/languageServerPlugin.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,5 +73,5 @@ export async function detectPreviewFlag(className: string, projectName: string):
7373
const expectedOptions = {
7474
[COMPILER_PB_ENABLE_PREVIEW_FEATURES]: "enabled",
7575
};
76-
return await checkProjectSettings(className, projectName, true, expectedOptions);
76+
return checkProjectSettings(className, projectName, true, expectedOptions);
7777
}

src/utility.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,17 +56,17 @@ function logMessage(message: ILoggingMessage): void {
5656

5757
export async function showInformationMessage(message: ILoggingMessage, ...items: string[]): Promise<string | undefined> {
5858
logMessage(message);
59-
return await vscode.window.showInformationMessage(message.message, ...items);
59+
return vscode.window.showInformationMessage(message.message, ...items);
6060
}
6161

6262
export async function showWarningMessage(message: ILoggingMessage, ...items: string[]): Promise<string | undefined> {
6363
logMessage(message);
64-
return await vscode.window.showWarningMessage(message.message, ...items);
64+
return vscode.window.showWarningMessage(message.message, ...items);
6565
}
6666

6767
export async function showErrorMessage(message: ILoggingMessage, ...items: string[]): Promise<string | undefined> {
6868
logMessage(message);
69-
return await vscode.window.showErrorMessage(message.message, ...items);
69+
return vscode.window.showErrorMessage(message.message, ...items);
7070
}
7171

7272
export async function showInformationMessageWithTroubleshooting(message: ITroubleshootingMessage, ...items: string[]): Promise<string | undefined> {

test/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ async function main(): Promise<void> {
1717
// Download VS Code, unzip it and run the integration test
1818
await runTests({ extensionDevelopmentPath, extensionTestsPath });
1919
} catch (err) {
20-
console.error("Failed to run tests");
2120
process.exit(1);
2221
}
2322
}

tslint.json

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,11 @@
77
],
88
"no-unused-expression": true,
99
"no-duplicate-variable": true,
10-
"max-classes-per-file": [
11-
false
10+
"max-classes-per-file": false,
11+
"no-implicit-dependencies": [
12+
false, // Turned off due to: https://github.com/microsoft/vscode/issues/78019
13+
"dev"
1214
],
13-
"no-implicit-dependencies": [true, "dev"],
1415
"no-empty": false,
1516
"object-literal-sort-keys": false,
1617
"curly": true,
@@ -24,15 +25,17 @@
2425
"check-separator",
2526
"check-type"
2627
],
27-
"semicolon": [
28-
"always"
29-
],
28+
"semicolon": true,
3029
"triple-equals": true,
3130
"max-line-length": [
3231
true,
3332
150
34-
],
33+
],
3534
"no-angle-bracket-type-assertion": false,
36-
"no-console": ["log","error"]
35+
"no-console": [
36+
true,
37+
"log",
38+
"error"
39+
]
3740
}
3841
}

0 commit comments

Comments
 (0)