You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
c533715 extension/CHANGELOG.md: prepare for v0.42.0
9875794 extension/src/goTelemetry: increase the prompt rate to 5%
13eebda extension/test/integration: disable local dlv install tests
64865db extension/src/goToolsInformation: update gopls version
61901bb go.mod: update golang.org/x/telemetry dependency
5790163 extension: npm audit fix (braces, yarn)
982638e docs/features.md: add details about custom formatter setting
7a532aa extension/src/goEnv: set GOTOOLCHAIN=auto by default
4cd8eb1 extension: stop referencing go.languageServerExperimentalFeatures
cb91241 extension/src/goTelemetry: set telemetry env vars
c05badc extension/src/goSurvey: fix a bug in HaTS survey prompting
639ce0c extension/test/gopls: fix writeVulns tests
dfdb3b8 extension/tools: update license.sh to work with extension/LICENSE
5584351 extension/tools/goplssetting: update to work with gopls v0.16.0 settings
540e146 extension/package.json: edit default launch package dir
1d1fe76 extension/src: require go1.19+ for tools installation
65d72fd extension/src/goEnvironmentStatus: fix error string
5d8af43 extension/src/util: do not use cached go version with GOTOOLCHAIN
f907536 docs: fix typo in debugging.md
fe57357 docs/faq.md: update the vscode default text mate rule project
ff0beea extension/src/goInstallTools: strengthing minimum go version requirement
It was a clean merge. Updated package.json version using
npx vsce -o /tmp/go-0.42.0.vsix 0.42.0
For #3453
Change-Id: I42f33614375e38c8f24ab0a2c4f8f4d3e6ef6cab
Copy file name to clipboardExpand all lines: docs/features.md
+26-3Lines changed: 26 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -194,7 +194,15 @@ Format code and organize imports, either manually or on save.
194
194
195
195
The extension formats Go code, organizes imports, and removes unused imports by default. For different behavior, please override per-language default settings following [the instruction](advanced.md#formatting-code-and-organizing-imports).
196
196
197
-
When organizing imports, the imported packages are grouped in the default `goimports` style. In order to group some packages after 3rd-party packages, use [`"gopls": { "formatting.local": <comma-separated imports prefix>}`](settings.md#formattinglocal).
197
+
#### Organizing imports
198
+
199
+
When organizing imports, the imported packages are grouped in the default `goimports` style. In order to group some packages after 3rd-party packages, use the [`"formatting.local"`](settings.md#formattinglocal) setting.
@@ -204,8 +212,23 @@ The extension organizes imports automatically and can add missing imports if the
204
212
205
213
#### Custom formatter
206
214
207
-
In addition to the default `gofmt`-style formatter, the Go language server supports `gofumpt`-style formatting. You can enable `gofumpt` formatting by setting `"gopls.formatting.gofumpt"`.
208
-
You can also configure to use other custom formatter by using the `"go.formatTool"` setting. The custom formatter must operate on file contents from STDIN, and output the formatted result to STDOUT.
215
+
In addition to the default [`go fmt`](https://pkg.go.dev/cmd/gofmt) style formatter, the language server (`gopls`) supports `github.com/mvdan/gofumpt` style formmating. Use gopls's [`formatting.gofumpt`](settings.md#formattinggofumpt) setting:
216
+
217
+
```json
218
+
"gopls": { "fomatting.gofumpt": true }
219
+
```
220
+
221
+
You can also configure to use other custom formatter (`golines`) by using the `"go.formatTool"` setting. The custom formatter must operate on file contents from STDIN, and output the formatted result to STDOUT.
0 commit comments