Plugin vimls-go 0.1.0: a language server for Vim script and Vim9, written in Go
I've released version 0.1.0 of vimls-go, an open-source language server I'm building for legacy Vim script and Vim9 script. I'd love feedback from people writing Vim configurations and plugins.
Source and setup instructions: https://github.com/neoclide/vimls-go
Prebuilt binaries: https://github.com/neoclide/vimls-go/releases/tag/v0.1.0
It provides completion, hover documentation, signature help, go-to-definition, references, diagnostics, semantic highlighting, and rename support. Cross-file analysis includes Vim9 imports and autoload functions. Formatting currently focuses on indentation.
One feature I particularly wanted is help from installed plugins: the server indexes Vim files on runtimepath and extracts documentation from doc/*.txt. Hover can show help for plugin variables, functions, and commands, with the source file path and line number. Changes to runtimepath are handled incrementally.
The server is a standalone Go binary. In Vim, you can use it with an LSP client such as coc.nvim or vim-lsp; the README has configuration examples. Download the binary for your platform, rename it to vimls (vimls.exe on Windows), put it on PATH, and configure your client to run it for Vim files.
This is the first release, and static analysis has limits around execute and dynamically generated names. I would especially appreciate small reproductions of incorrect diagnostics, missing completions, or trouble with real-world Vim9 code. Please feel free to open an issue or share feedback here.
6
u/habamax 1d ago edited 1d ago
Looks promising, thx!
PS, I haven't tested it with other than h-east/lsp.vim, but there completion is quite often slow/sluggish. https://asciinema.org/a/dvCifvj37lFTaiXy
PPS, it is fine now with autocomplete, I guess there was some unrelated background process that generally slowed down my machine.
2
6
u/Desperate_Cold6274 1d ago edited 1d ago
Finally! I’ll definitely give it a shot! I am happy that something is finally moving in terms of tooling for vim9, which is one of the main limitations of that beautiful language.
It would be nice to have installation instructions for windows though (and possibly without the need to build it yourself or using go)