Skip to content

Commit 2f6111a

Browse files
committed
[release] prepare v0.23.1 release
f641be9 package.json: change the default format tool to goimports ac61291 package.json: update LSP and DAP libraries b085ad4 src/config: add toolsEnvVars to the config list to watch 977bb74 src/goTools: explicitly specify staticcheck, gotests package paths ace0cf7 tools: run gopls setting update in tools/generate.go 68e5a0b src/goModules: fix a bug in formatTool warning prompt 658a52b src/goLanguageServer: show command failure error messages from gopls fb5bc5b test/integration/goDebug: fix windows tests a8bf0c2 CHANGELOG.md: v0.23.0 release note 5c340dd src/goDebugFactory: redirect stdout/stderr from dlv to Debug Console fd03282 src/goLint: switch the default lint tool to staticcheck a64f4f0 src/config: suppress welcome page & update check in cloud-based ides 0b1ae1d docs/settings.md: sync gopls settings @v0.6.6 f6391a2 src/goLanguageServer: replace [] foldingRange response with undefined 80f450f src/welcome: remove unused variables 808b02f src/goDebugFactory.ts: fix error in exec mode 9fe63c5 welcome: remove gopls announcement from the welcome page Change-Id: Ic4ff3cb80da274c3806436c1f63ed0a16b0b0837
2 parents 35dafc6 + f641be9 commit 2f6111a

28 files changed

+18422
-18496
lines changed

.github/workflows/release-nightly.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ jobs:
5757
go get github.com/sqs/goreturns
5858
go get github.com/uudashr/gopkgs/v2/cmd/gopkgs
5959
go get github.com/zmb3/gogetdoc
60-
go get golang.org/x/lint/golint
60+
go get honnef.co/go/tools/...
6161
go get golang.org/x/tools/cmd/gorename
6262
go get golang.org/x/tools/gopls
6363
go get github.com/cweill/gotests/...

.github/workflows/test-long-all.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ jobs:
5353
go get github.com/sqs/goreturns
5454
go get github.com/uudashr/gopkgs/v2/cmd/gopkgs
5555
go get github.com/zmb3/gogetdoc
56-
go get golang.org/x/lint/golint
56+
go get honnef.co/go/tools/...
5757
go get golang.org/x/tools/cmd/gorename
5858
go get golang.org/x/tools/gopls
5959
go get github.com/cweill/gotests/...

.github/workflows/test-long.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ jobs:
5252
go get github.com/sqs/goreturns
5353
go get github.com/uudashr/gopkgs/v2/cmd/gopkgs
5454
go get github.com/zmb3/gogetdoc
55-
go get golang.org/x/lint/golint
55+
go get honnef.co/go/tools/...
5656
go get golang.org/x/tools/cmd/gorename
5757
go get golang.org/x/tools/gopls
5858
go get github.com/cweill/gotests/...

.github/workflows/test-smoke.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
go get github.com/sqs/goreturns
5151
go get github.com/uudashr/gopkgs/v2/cmd/gopkgs
5252
go get github.com/zmb3/gogetdoc
53-
go get golang.org/x/lint/golint
53+
go get honnef.co/go/tools/...
5454
go get golang.org/x/tools/cmd/gorename
5555
go get golang.org/x/tools/gopls
5656
go get github.com/cweill/gotests/...

build/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ COPY --from=gobuilder /usr/local/go /usr/local/go
2626
ENV PATH /workspace/vscodego/go/bin:/go/bin:/usr/local/go/bin:${PATH}
2727
ENV DEBIAN_FRONTEND noninteractive
2828

29-
RUN apt-get -qq update && apt-get install -qq -y libnss3 libgtk-3-dev libxss1 libasound2 xvfb libsecret-1-0 > /dev/null
29+
RUN apt-get -qq update && apt-get install -qq -y libnss3 libgtk-3-dev libxss1 libasound2 xvfb libsecret-1-0 jq > /dev/null
3030
RUN npm install -g typescript vsce
3131

3232
WORKDIR /workspace

build/all.bash

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ run_test() {
5151
npm run lint
5252

5353
echo "**** Run settings generator ****"
54-
go run tools/generate.go -w=false
54+
go run tools/generate.go -w=false -gopls=true
5555

5656
echo "**** Check if vsce works ****"
5757
vsce package
@@ -115,7 +115,7 @@ install_dependencies() {
115115
GO111MODULE=on go get github.com/sqs/goreturns
116116
GO111MODULE=on go get github.com/uudashr/gopkgs/v2/cmd/gopkgs
117117
GO111MODULE=on go get github.com/zmb3/gogetdoc
118-
GO111MODULE=on go get golang.org/x/lint/golint
118+
GO111MODULE=on go get honnef.co/go/tools/...
119119
GO111MODULE=on go get golang.org/x/tools/cmd/gorename
120120
GO111MODULE=on go get github.com/go-delve/delve/cmd/dlv@master
121121
}

docs/settings.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ Flags to pass to format tool (e.g. ["-s"]). Not applicable when using the langua
235235
Not applicable when using the language server. Choosing 'goimports', 'goreturns', or 'gofumports' will add missing imports and remove unused imports.<br/>
236236
Allowed Options: `gofmt`, `goimports`, `goreturns`, `goformat`, `gofumpt`, `gofumports`
237237

238-
Default: `"goreturns"`
238+
Default: `"goimports"`
239239
### `go.generateTestsFlags`
240240

241241
Additional command line flags to pass to `gotests` for generating tests.
@@ -312,9 +312,9 @@ Default: `"package"`
312312
### `go.lintTool`
313313

314314
Specifies Lint tool name.<br/>
315-
Allowed Options: `golint`, `golangci-lint`, `revive`, `staticcheck`
315+
Allowed Options: `staticcheck`, `golint`, `golangci-lint`, `revive`
316316

317-
Default: `"golint"`
317+
Default: `"staticcheck"`
318318
### `go.liveErrors`
319319

320320
Use gotype on the file currently being edited and report any semantic or syntactic errors found after configured delay. Not applicable when using the language server.
@@ -581,13 +581,13 @@ Example Usage:
581581

582582
| Properties | Description |
583583
| --- | --- |
584-
| `gc_details` | gc_details controls calculation of gc annotations. <br/> <br/> Default: `false` |
585-
| `generate` | generate runs `go generate` for a given directory. <br/> <br/> Default: `true` |
586-
| `regenerate_cgo` | regenerate_cgo regenerates cgo definitions. <br/> <br/> Default: `true` |
587-
| `test` | test runs `go test` for a specific test function. <br/> <br/> Default: `false` |
588-
| `tidy` | tidy runs `go mod tidy` for a module. <br/> <br/> Default: `true` |
589-
| `upgrade_dependency` | upgrade_dependency upgrades a dependency. <br/> <br/> Default: `true` |
590-
| `vendor` | vendor runs `go mod vendor` for a module. <br/> <br/> Default: `true` |
584+
| `gc_details` | Toggle the calculation of gc annotations. <br/> Default: `false` |
585+
| `generate` | Runs `go generate` for a given directory. <br/> Default: `true` |
586+
| `regenerate_cgo` | Regenerates cgo definitions. <br/> Default: `true` |
587+
| `test` | Runs `go test` for a specific set of test or benchmark functions. <br/> Default: `false` |
588+
| `tidy` | Runs `go mod tidy` for a module. <br/> Default: `true` |
589+
| `upgrade_dependency` | Upgrades a dependency in the go.mod file for a module. <br/> Default: `true` |
590+
| `vendor` | Runs `go mod vendor` for a module. <br/> Default: `true` |
591591
### `ui.completion.completionBudget`
592592

593593
(For Debugging) completionBudget is the soft latency goal for completion requests. Most

docs/tools.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,14 @@ This tool provides support for the [`Go: Generate Interface Stubs`](features.md#
6060

6161
This tool provides support for the [`Go: Generate Unit Tests`](features.md#generate-unit-tests) set of commands.
6262

63-
### [`golint`]
63+
### [`staticcheck`]
6464

65-
This is the default lint tool. Other lint tools can be used by configuring the [`"go.lintTool"`](settings.md#go.lintTool) setting. Other options include:
65+
This is the default lint tool. See the [full list of checks](https://staticcheck.io/docs/checks) that `staticcheck` provides. Other lint tools can be used by configuring the [`"go.lintTool"`](settings.md#go.lintTool) setting.
66+
Other options include:
6667

67-
* [`staticcheck`]: This tool provides a great deal of useful checks that are not provided by [`golint`]. See the full list at [staticcheck.io/docs/checks](https://staticcheck.io/docs/checks). It is also officially supported by the [Go team at Google](https://staticcheck.io/sponsors).
68-
* [`golangci-lint`]: This tool combines a number of existing lint tools, including [staticcheck](#staticcheck), into one interface.
68+
* [`golangci-lint`]: This meta-linter combines a number of existing lint tools, including [staticcheck](#staticcheck), into one interface.
6969
* [`revive`]: This tool is an enhancement on top of [`golint`], and it provides additional checks.
70+
* [`golint`]: This used to be the default linter used by this extension before it was officially deprecated.
7071

7172
You can use the [`"go.lintFlags"`](settings.md#go.lintFlags) setting to further configure your linter of choice. Most linters can be configured via special configuration files, but you may still need to pass these command-line flags. The configuration documentation for each supported linter is listed here:
7273

@@ -115,11 +116,11 @@ It can also be used to provide the [go to definition](features.md#go-to-definiti
115116

116117
* [`gogetdoc`], [`godef`], [`godoc`]: these are documentation tools used for the [go to definition](features.md#go-to-definition), [signature help](features.md#signature-help), and [quick info on hover](features.md#quick-info-on-hover) in the legacy mode. [`guru`](#guru) can also be used, but only for the [go to definition](features.md#go-to-definition) behavior. Configure this via the [`"go.docsTool"`](settings.md#go.docsTool) setting.
117118

118-
* [`goreturns`], [`gofmt`], [`goimports`]: Formatting tools are used by the [formatting and import organization](features.md#format-and-organize-imports) features. [`goreturns`] is used by default in the legacy mode. It formats the file according to the industry standard [`gofmt`] style, organizes imports, and fills in default return values for functions. Other tools can be used for formatting instead; this can be configured with the [`"go.go.formatTool"`](settings.md#formatTool) setting. Note that [`goreturns`] does not have support for Go modules.
119+
* [`goimports`], [`gofmt`]: Formatting tools are used by the [formatting and import organization](features.md#format-and-organize-imports) features. [`goreturns`] is used by default in the legacy mode. It formats the file according to the industry standard [`gofmt`] style, organizes imports, and fills in default return values for functions. Other tools can be used for formatting instead; this can be configured with the [`"go.go.formatTool"`](settings.md#formatTool) setting.
119120

120-
* [`goimports`], which applies the default `gofmt` style and organizes imports, but without the behavior of filling in default return values
121121
* [`gofmt`] only formats the file, without import organization or filling in return values
122122
* [`goformat`] is a configurable version of [`gofmt`]
123+
* [`goreturns`] fills in default return values for functions, in addition to applying `goimports`-style formatting. This tool does not have support for Go modules.
123124

124125
* Diagnostics tools: By default, [`gotype-live`], [`go vet`], and [`golint`] are used to provide [build](features.md#build-errors), [vet](features.md#vet-errors), and [lint](features.md#lint-errors) errors. [`gotype-live`] provides build errors as you type, while `go build` can be used to show build errors only on save. [`gotype-live`] does not work with modules.
125126

go.mod

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module github.com/golang/vscode-go
2+
3+
go 1.16

0 commit comments

Comments
 (0)