From 058eccf17f1b0eebd607581591828531d768b98e Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Sun, 10 Mar 2019 18:52:15 -0700 Subject: [PATCH] Log when on save processes start #1869 --- src/goBuild.ts | 2 ++ src/goLint.ts | 8 +++++--- src/goVet.ts | 2 ++ 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/goBuild.ts b/src/goBuild.ts index eda7c6854..1605c2405 100644 --- a/src/goBuild.ts +++ b/src/goBuild.ts @@ -94,6 +94,7 @@ export function goBuild(fileUri: vscode.Uri, isMod: boolean, goConfig: vscode.Wo } if (buildWorkspace && currentWorkspace && !isTestFile) { + outputChannel.appendLine(`Starting building the current workspace at ${currentWorkspace}`); return getNonVendorPackages(currentWorkspace).then(pkgs => { running = true; return runTool( @@ -116,6 +117,7 @@ export function goBuild(fileUri: vscode.Uri, isMod: boolean, goConfig: vscode.Wo let currentGoWorkspace = getCurrentGoWorkspaceFromGOPATH(getCurrentGoPath(), cwd); let importPath = currentGoWorkspace ? cwd.substr(currentGoWorkspace.length + 1) : '.'; running = true; + outputChannel.appendLine(`Starting building the current package at ${cwd}`); return runTool( buildArgs.concat('-o', tmpPath, importPath), cwd, diff --git a/src/goLint.ts b/src/goLint.ts index 5abc425a1..beb82237d 100644 --- a/src/goLint.ts +++ b/src/goLint.ts @@ -105,10 +105,12 @@ export function goLint(fileUri: vscode.Uri, goConfig: vscode.WorkspaceConfigurat if (scope === 'workspace' && currentWorkspace) { args.push('./...'); - } - - if (scope === 'file') { + outputChannel.appendLine(`Starting linting the current workspace at ${currentWorkspace}`); + } else if (scope === 'file') { args.push(fileUri.fsPath); + outputChannel.appendLine(`Starting linting the current file at ${fileUri.fsPath}`); + } else { + outputChannel.appendLine(`Starting linting the current package at ${cwd}`); } running = true; diff --git a/src/goVet.ts b/src/goVet.ts index e633862c4..03d3bb2ca 100644 --- a/src/goVet.ts +++ b/src/goVet.ts @@ -75,6 +75,8 @@ export function goVet(fileUri: vscode.Uri, goConfig: vscode.WorkspaceConfigurati vetArgs = ['tool', 'vet', ...vetFlags, ...tagsArg, '.']; } + outputChannel.appendLine(`Starting "go vet" under the folder ${cwd}`); + running = true; return runTool( vetArgs,