Skip to content

Commit

Permalink
goLanguageServer: add go version and OS to the opt-out form
Browse files Browse the repository at this point in the history
Change-Id: Iea03425b6553fa5b0b7f2fcf36a027455bc18dc0
Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/303769
Trust: Rebecca Stambler <[email protected]>
Run-TryBot: Rebecca Stambler <[email protected]>
TryBot-Result: kokoro <[email protected]>
Reviewed-by: Hyang-Ah Hana Kim <[email protected]>
  • Loading branch information
stamblerre committed Mar 23, 2021
1 parent 9806edd commit caf19fa
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/goLanguageServer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -314,14 +314,21 @@ async function promptForGoplsOptOutSurvey(cfg: GoplsOptOutConfig, msg: string):
}
let goplsVersion = await getLocalGoplsVersion(latestConfig);
if (!goplsVersion) {
goplsVersion = 'not found';
goplsVersion = 'no gopls version found';
}
goplsVersion = `gopls/${goplsVersion}`;
const goV = await getGoVersion();
let goVersion = 'no go version found';
if (goV) {
goVersion = `go${goV.format(true)}`;
}
const version = [goplsVersion, goVersion, process.platform].join(';');
switch (s.title) {
case 'Yes':
cfg.prompt = false;
await vscode.env.openExternal(
vscode.Uri.parse(
`https://docs.google.com/forms/d/e/1FAIpQLSdeqOas92JBD3Qkr-XyIiCuPeZvjmUuL07vu3WFNeaZZvrJDQ/viewform?entry.1049591455=${goplsVersion}&resourcekey=0-VmBGvZtiC8z9qytyA8ThnA`
`https://docs.google.com/forms/d/e/1FAIpQLScITGOe2VdQnaXigSIiD19VxN_2KLwjMszZOMZp9TgYvTOw5g/viewform?entry.1049591455=${version}&gxids=7826`
)
);
break;
Expand Down

0 comments on commit caf19fa

Please sign in to comment.