x/tools/gopls: add willSaveWaitUntil support for formatting and goimports #57281
Labels
FeatureRequest
Issues asking for a new feature that does not need a proposal.
gopls
Issues related to the Go language server, gopls.
help wanted
Refactoring
Issues related to refactoring tools
Tools
This label describes issues relating to any tools in the x/tools repository.
Milestone
gopls version
go env
If this is relevant, I'll fill it in, just ask. For now I consider this spam.
What did you do?
After Neovim added support for
textDocument/willSaveWaitUntil
(neovim/neovim#21315). I started gopls to see if it supports this as it can save a roundtrip and would allow me to get rid of my gopls-specific goimports stanza. It currently looks like this:What did you expect to see?
I expected the
server_capabilities
to contain:So that Neovim (and other LSP clients that support this) can notify gopls before saving and apply last-minute edits returned from gopls.
What did you see instead?
The
server_capabilities
does not contain what I expected.Editor and settings
Neovim 0.9.0-dev (HEAD as of today). The client capabilities are:
The text was updated successfully, but these errors were encountered: