What versions of Vim and Go are supported with
The supported versions of Vim/GVim are most effectively summarised by the Travis build matrix:
Other combinations of Vim and Go may work.
For advice on building Vim from source, see here
Neovim is not supported; see #121 for discussion about potentially adding such support.
What do I need in my
Assuming you have the plugin installed correctly, a minimal
.vimrc is shown in:
Why have you created
govim? What is/was wrong with
Secondly, some history.
vim-go predates the channel support in Vim8. As such the way it emerged and evolved is very much a function of the world that existed back in 2014.
With that said, there is absolutely nothing wrong with
vim-go is also using
gopls for some commands/functionality.
github.com/myitcv/govim/cmd/govim is an experiment. It's an experiment that is looking to test the hypothesis that writing Vim plugins in Go (to support developing in Go):
- will make for more readable/maintainable code
- will enable more people to contribute
- will allow common, intuitive, easy-to-understand building blocks to be created using Go primitives as opposed to VimScript primitives. i.e. we could provide a Go function/method that gets the current buffer contents rather than relying on knowledge that we need to evaluate the expression
join(getline(0, "$"), "\n")
- will, over time, allow a more usable API to establish itself
- will allow for the use of existing developing tooling whilst working on
github.com/myitcv/govim/cmd/govim(or any plugin that is build using
github.com/myitcv/govimfor that matter)
Why should I use
vim-lsp/...? Why is
govim not language agnostic?
Building on the answer above,
govim was started as an experiment to test whether writing Vim8 plugins in Go would be easier, more fun etc. This answer adds my current (2019-04-18) personal (myitcv) thoughts. Note however that I'm very willing to be steered in a different direction on any of these points and more!
- I focussed on
gopls(and by extension, Go) in order to help quickly iterate on progress in
gopls. Hence my goal was/is not "I don't want to support other languages/LSP implementations, ever"; rather, "I'm currently focussing on
- there is therefore no particular reason to prefer it over
coc.nvimor any of the other related projects.
vim-goat least is far more mature in terms of code life. I've not tried
- whilst there are (large) parts of
govimthat are language agnostic (because all its doing is talking LSP to
gopls), having my stated goal be that
govimis Go-specific (for now) feels like the most efficient way to iterate on the progress being made with
goplsbut also to flush out whether there are any Go-specific bits where the LSP spec itself needs to change. Making
govim(or some derivative of it) language agnostic is being tracked in https://github.com/myitcv/govim/issues/194, but again, this not my primary goal right now
Is anyone actually using
At least one person (me!) is using it 100% of the time, as a direct replacement for
vim-go. Yes there are rough edges, but it's easy(ish) to iron out those rough edges, and the speed benefits of
gopls make it vastly preferable.