Commit Graph

19 Commits

Author SHA1 Message Date
Carlos A Becker 1f10767725 gopls/doc: update neovim examples for nvim 0.7
On neovim 0.7-dev `apply_workspace_edit` needs the encoding.

This PR updates the organize imports documentation example.

This does not break neovim v0.6+. Haven't tested in <=v0.5.

refs https://github.com/neovim/neovim/issues/14090

Change-Id: I82a08c54dd94e6aacb5aa30a19a1fa209ef5264b
GitHub-Last-Rev: f4072a0eec9c14a0efd618c1835e0d99c4a2d6f4
GitHub-Pull-Request: golang/tools#375
Reviewed-on: https://go-review.googlesource.com/c/tools/+/390417
Reviewed-by: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
2022-04-12 22:37:10 +00:00
Simon Drake 72442fe040 gopls: update neovim documentation for imitating goimports
The existing example is no longer recommended as it can have unintended
consequences; for example, if it is run while the cursor is in an
incomplete struct, it will fill in all struct fields.

This is described more at https://github.com/neovim/nvim-lspconfig/issues/115#issuecomment-866632451

Change-Id: I3640ddb747a69c864675c0483032037a5e777d59
GitHub-Last-Rev: 2335f017eb967785da28ddb1bc48fb820d59a07e
GitHub-Pull-Request: golang/tools#371
Reviewed-on: https://go-review.googlesource.com/c/tools/+/389194
Reviewed-by: Robert Findley <rfindley@google.com>
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
Trust: Hyang-Ah Hana Kim <hyangah@gmail.com>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
2022-03-02 15:07:28 +00:00
Simon Drake 625c871d3c gopls: update neovim documentation for using go.work
For golang/go#50955

Change-Id: I8882239868d060a444466a466d30c3de9aaa31ef
GitHub-Last-Rev: 6395f147165c7947eae50719fb03e65d95a4debf
GitHub-Pull-Request: golang/tools#370
Reviewed-on: https://go-review.googlesource.com/c/tools/+/388576
Trust: Nooras Saba‎ <saba@golang.org>
Reviewed-by: Robert Findley <rfindley@google.com>
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
2022-03-01 19:24:28 +00:00
Robert Findley cf66aec62b gopls: update coc.nvim documentation for using go.work
For golang/go#50955

Change-Id: Idab88d258ceab3312adccd97eb58ed64e5fb5053
Reviewed-on: https://go-review.googlesource.com/c/tools/+/382242
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
2022-02-04 14:04:20 +00:00
Akhil cadd57e399 docs: updated nvim-lspconfig link
This PR updates the link of nvim-lspconfig doc for gopls.

Change-Id: I9f64ca9c310af8a6c6392245c88eea666edf4657
GitHub-Last-Rev: 9774e504c77d7b0d00f932dd5af85563498a21b2
GitHub-Pull-Request: golang/tools#351
Reviewed-on: https://go-review.googlesource.com/c/tools/+/367254
Reviewed-by: Robert Findley <rfindley@google.com>
Trust: Robert Findley <rfindley@google.com>
Trust: Hyang-Ah Hana Kim <hyangah@gmail.com>
Run-TryBot: Hyang-Ah Hana Kim <hyangah@gmail.com>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
2021-12-08 15:21:23 +00:00
Francesco Renzi 6e9046bfcd gopls/doc: fix imports function for Neovim LSP
The documented Lua function for supporting imports with Neovim native
LSP support does work for imports, but also runs any other code action
available in the current range. For example, if the function was to run
with the user's cursor on an empty struct being initialized, the code
action for filling that struct would also run.
This change restricts the desired actions to only be organizeImports.

Fixes golang/go#47181

Change-Id: Ie4eb5961cb4405091477b79175acc7052ff16d4c
Reviewed-on: https://go-review.googlesource.com/c/tools/+/334749
Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
Trust: Hyang-Ah Hana Kim <hyangah@gmail.com>
Trust: Robert Findley <rfindley@google.com>
2021-07-15 13:35:41 +00:00
GGCristo de44776175 gopls/doc: Neovim v0.5 is now stable
Change-Id: Ia3078f9d321d17681b92fd9b00f6dd1cb3eff6d0
GitHub-Last-Rev: 5c2023007a2e6a6471ec75871f74dc3edfe91af9
GitHub-Pull-Request: golang/tools#329
Reviewed-on: https://go-review.googlesource.com/c/tools/+/332849
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Trust: Rebecca Stambler <rstambler@golang.org>
Trust: Cherry Mui <cherryyz@google.com>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
gopls-CI: kokoro <noreply+kokoro@google.com>
2021-07-12 22:00:43 +00:00
Sergey Kacheev 2140ccea5d fix the argument of the goimports example
After the last code correction, the name of the argument is different from the name used in the code.
Was "timeoutms" became "timeout_ms"

Change-Id: Id2c94b9a39ea162a9102e20e33b5ffcd019c5225
GitHub-Last-Rev: 4a2d3c8c6dee3f1995406772b70cfd41a2591071
GitHub-Pull-Request: golang/tools#301
Reviewed-on: https://go-review.googlesource.com/c/tools/+/309229
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Trust: Rebecca Stambler <rstambler@golang.org>
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
2021-04-12 17:45:26 +00:00
stephen f48e60bd82 add comment and check action type neovim goimports
Change-Id: Icfb3463546a889339f96720eb3e7603361e07fc7
GitHub-Last-Rev: 5aa0708d57ee9051561d2693edcb15f054b2f9e4
GitHub-Pull-Request: golang/tools#276
Reviewed-on: https://go-review.googlesource.com/c/tools/+/294529
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Trust: Rebecca Stambler <rstambler@golang.org>
Trust: Peter Weinberger <pjw@google.com>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
2021-02-23 16:31:27 +00:00
Rebecca Stambler d78b04bdf9 gopls/doc: clean up and slightly reorganize documentation
This is a first CL to clean up the gopls documentation. The main changes
are cosmetic (to correct warnings found by the MD Lint VS Code
extension), though some parts are reworded or moved around. Ultimately,
more work needs to be done, particularly on the user guide and features
overview.

My current thinking is that we should rename settings.md to
configuration and move the configuration piece out of the user guide,
and also reorganize the user guide to be more "getting started"
oriented.

I'm still not sure where miscellaneous items should go (e.g., working on
the Go distribution itself)--I deleted the FAQ because it seemed useless
and is probably not the most discoverable, but it's the only place that
comes to mind so far.

Change-Id: I3689362067672f7ad8d5e8fd97ca9c7c45cfc8c4
Reviewed-on: https://go-review.googlesource.com/c/tools/+/280595
Trust: Rebecca Stambler <rstambler@golang.org>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
Reviewed-by: Robert Findley <rfindley@google.com>
2021-01-14 06:55:38 +00:00
Jan Steinke 6c3993fd31 gopls: update link to nvim-lspconfig gopls configuration
The README of nvim-lspconfig was restructured and now the link is out-dated. This change reflects the change and brings it up-to-date.

Change-Id: If8a871a31390ac98eb783f89b58d22d1a42cb7ef
GitHub-Last-Rev: 80416bf48693f94474eb28026609fa1fa1b8257f
GitHub-Pull-Request: golang/tools#266
Reviewed-on: https://go-review.googlesource.com/c/tools/+/281254
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Trust: Robert Findley <rfindley@google.com>
2021-01-05 16:40:27 +00:00
Ainar Garipov 0f6027f0cc gopls/doc/vim.md: add table of contents, improve neovim docs
Change-Id: Ibc56cb676200df4282eeb38d0f63f239d2f962ab
Reviewed-on: https://go-review.googlesource.com/c/tools/+/278832
Reviewed-by: Robert Findley <rfindley@google.com>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Trust: Rebecca Stambler <rstambler@golang.org>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
2020-12-28 17:44:24 +00:00
Himanshu 02d27ecf39 Change require 'nvim_lsp' to 'lspconfig' in vim.md
Change-Id: I3cab635216b6e104e79801cc26e0935d75d5c53a
GitHub-Last-Rev: 009b01191fc9a85fa3f5757b41e1004b2584bc5d
GitHub-Pull-Request: golang/tools#258
Reviewed-on: https://go-review.googlesource.com/c/tools/+/273386
Reviewed-by: Robert Findley <rfindley@google.com>
Trust: Rebecca Stambler <rstambler@golang.org>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
gopls-CI: kokoro <noreply+kokoro@google.com>
2020-12-01 06:06:10 +00:00
Ainar Garipov 34b80a0a46 gopls/doc: update and expand the nvim documentation
Change-Id: If7df2c5b0cefb73e96641187bcd721962d72cb4d
Reviewed-on: https://go-review.googlesource.com/c/tools/+/257437
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Trust: Rebecca Stambler <rstambler@golang.org>
Trust: Robert Findley <rfindley@google.com>
2020-09-25 15:01:35 +00:00
Ellison Leão cd5a53e07f gopls/docs: adding nvim-lsp option in gopls README file
Change-Id: Ic44210e227559c8e1cd5cf1350cde69e2817f5e3
GitHub-Last-Rev: c020218392160d03a9448eda62e098fe0c91a063
GitHub-Pull-Request: golang/tools#221
Reviewed-on: https://go-review.googlesource.com/c/tools/+/227442
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2020-04-07 19:18:07 +00:00
Ainar Garipov 846f856e7d gopls/doc: fix issue links for vim-lsc
Change-Id: Iecdc087da7e48a170616e0453c5c4fe1a45ef95e
Reviewed-on: https://go-review.googlesource.com/c/tools/+/201419
Reviewed-by: Ian Cottrell <iancottrell@google.com>
2019-10-17 10:18:17 +00:00
Shengjing Zhu 5fa5b1782b gopls/doc: instructions for adding settings in coc.nvim
Change-Id: I7d69477cc103e8e45b0e9394e32945a0d8ee19b3
Reviewed-on: https://go-review.googlesource.com/c/tools/+/200868
Reviewed-by: Ian Cottrell <iancottrell@google.com>
2019-10-14 14:15:50 +00:00
Ainar Garipov 1ccc110ba9 gopls/doc/vim.md: enable suppress_stderr for natebosch/vim-lsc
By default, github.com/natebosch/vim-lsc shows messages from stderr in
vim's :messages, which may cause problems and is generally annoying.
Suggest disabling that by setting suppress_stderr to v:true.

Change-Id: If997b8f8fd036a1ac08ba74a3886f33ff71413c2
Reviewed-on: https://go-review.googlesource.com/c/tools/+/194137
Reviewed-by: Ian Cottrell <iancottrell@google.com>
2019-09-16 02:06:55 +00:00
Ian Cottrell 062dbaebb6 cmd/gopls: add documentation
Much of this documentation has been collated from other sources,
but this pulls it all into one coherent and public structure in
a way that allows us to peer review changes.

Change-Id: Ic24a59bb92b27ec85d2f57affcf2eb396c9de3c0
Reviewed-on: https://go-review.googlesource.com/c/tools/+/191741
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2019-08-27 15:23:08 +00:00