diff --git a/src/goBaseCodelens.ts b/src/goBaseCodelens.ts index 8aaa83dde..01bc4ac2f 100644 --- a/src/goBaseCodelens.ts +++ b/src/goBaseCodelens.ts @@ -5,7 +5,6 @@ export abstract class GoBaseCodeLensProvider implements vscode.CodeLensProvider protected enabled: boolean = true; private onDidChangeCodeLensesEmitter = new vscode.EventEmitter(); - public get onDidChangeCodeLenses(): vscode.Event { return this.onDidChangeCodeLensesEmitter.event; } diff --git a/src/goInstallTools.ts b/src/goInstallTools.ts index e722635d1..8c00d6d9c 100644 --- a/src/goInstallTools.ts +++ b/src/goInstallTools.ts @@ -439,7 +439,6 @@ export function updateGoPathGoRootFromConfig(): Promise { process.env[pathEnvVar] += path.delimiter + goRuntimeBasePath; } - return new Promise((resolve, reject) => { cp.execFile(goRuntimePath, ['env', 'GOPATH', 'GOROOT'], (err, stdout, stderr) => { if (err) { @@ -502,7 +501,6 @@ export function offerToInstallTools() { } }); - function promptForInstall(missing: string[], goVersion: SemVersion) { const installItem = { title: 'Install', diff --git a/src/goMain.ts b/src/goMain.ts index e322bce7e..e8e20ca7c 100644 --- a/src/goMain.ts +++ b/src/goMain.ts @@ -325,7 +325,6 @@ export function activate(ctx: vscode.ExtensionContext): void { const testCodeLensProvider = new GoRunTestCodeLensProvider(); const referencesCodeLensProvider = new GoReferencesCodeLensProvider(); - ctx.subscriptions.push(vscode.languages.registerCodeActionsProvider(GO_MODE, new GoCodeActionProvider())); ctx.subscriptions.push(vscode.languages.registerCodeLensProvider(GO_MODE, testCodeLensProvider)); ctx.subscriptions.push(vscode.languages.registerCodeLensProvider(GO_MODE, referencesCodeLensProvider)); @@ -504,7 +503,6 @@ export function activate(ctx: vscode.ExtensionContext): void { }); } - if (updatedGoConfig['enableCodeLens']) { testCodeLensProvider.setEnabled(updatedGoConfig['enableCodeLens']['runtest']); referencesCodeLensProvider.setEnabled(updatedGoConfig['enableCodeLens']['references']); diff --git a/src/goModules.ts b/src/goModules.ts index bc23dd8e8..3115a29b0 100644 --- a/src/goModules.ts +++ b/src/goModules.ts @@ -74,7 +74,6 @@ export async function getModFolderPath(fileuri: vscode.Uri): Promise { return goModEnvResult; } - let moduleUsageLogged = false; function logModuleUsage() { if (moduleUsageLogged) { diff --git a/src/goOutline.ts b/src/goOutline.ts index f4eeee61f..9c3ccfaa3 100644 --- a/src/goOutline.ts +++ b/src/goOutline.ts @@ -119,7 +119,6 @@ const goKindToCodeKind: { [key: string]: vscode.SymbolKind } = { 'struct': vscode.SymbolKind.Struct, }; - function convertToCodeSymbols( document: vscode.TextDocument, decls: GoOutlineDeclaration[], @@ -130,7 +129,6 @@ function convertToCodeSymbols( (decls || []).forEach(decl => { if (!includeImports && decl.type === 'import') return; - if (decl.label === '_' && decl.type === 'variable') return; const label = decl.receiverType diff --git a/src/stateUtils.ts b/src/stateUtils.ts index 9eacc147b..dafa0d70e 100644 --- a/src/stateUtils.ts +++ b/src/stateUtils.ts @@ -19,4 +19,3 @@ export function updateGlobalState(key: string, value: any) { export function setGlobalState(state: vscode.Memento) { globalState = state; } - diff --git a/src/testUtils.ts b/src/testUtils.ts index 577866620..dddf6cabf 100644 --- a/src/testUtils.ts +++ b/src/testUtils.ts @@ -13,7 +13,6 @@ import { getNonVendorPackages } from './goPackages'; import { getCurrentGoWorkspaceFromGOPATH, parseEnvFile } from './goPath'; import { getBinPath, getCurrentGoPath, getGoVersion, getToolsEnvVars, LineBuffer, resolvePath } from './util'; - const sendSignal = 'SIGKILL'; const outputChannel = vscode.window.createOutputChannel('Go Tests'); const statusBarItem = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Left); diff --git a/src/util.ts b/src/util.ts index 73f360418..bbb433353 100644 --- a/src/util.ts +++ b/src/util.ts @@ -371,7 +371,7 @@ function resolveToolsGopath(): string { } export function getBinPath(tool: string): string { - const alternateTools: {[key: string]: string} = vscode.workspace.getConfiguration('go', null).get('alternateTools'); + const alternateTools: { [key: string]: string } = vscode.workspace.getConfiguration('go', null).get('alternateTools'); const alternateToolPath: string = alternateTools[tool]; return getBinPathWithPreferredGopath( diff --git a/test/utils.test.ts b/test/utils.test.ts index 91b653bf6..29b6ea1fb 100644 --- a/test/utils.test.ts +++ b/test/utils.test.ts @@ -62,4 +62,3 @@ suite('GuessPackageNameFromFile Tests', () => { .then(() => done(), done); }); }); - diff --git a/tslint.json b/tslint.json index 9c8f7432e..b784fdd14 100644 --- a/tslint.json +++ b/tslint.json @@ -70,7 +70,7 @@ "new-parens": true, "no-arg": true, "no-conditional-assignment": true, - // "no-consecutive-blank-lines": true, + "no-consecutive-blank-lines": true, "no-construct": true, "no-debugger": true, "no-duplicate-super": true, @@ -167,4 +167,4 @@ "check-type" ] } -} \ No newline at end of file +}