Open dineth-lochana opened 3 months ago
lspconfig.gopls = add_lsp { name = "gopls", language = "go", file_patterns = { "%.go$" }, command = { "gopls", "serve" }, verbose = true, quit_timeout = 180 }
I've change my config to this, and now I get this
It seems to be stuck reloading still.. Sigh...
I though that recent gopls versions might have done something to break compatability, so I tried to build and use gopls 0.14, 12, and 10 but no cigar, they all keep restarting everytime I do something.
Honestly pretty stumped by now.
https://github.com/lite-xl/lite-xl-lsp/issues/43 The same issue seems to be visible here as well. Seems that seems to be unsolved. Welp...
https://github.com/lite-xl/lite-xl-lsp/issues/31 Then again this shows gopls from working, so my idea is to use gopls and lite-xl-lsp from around 2022 to see if that's the case.
gopls/v0.9.5 Gopls 9.5 works! but only it seems to work! Gopls 10.x and onwards don't seem to work at all for me, can anybody else confirm this
My first guess: you're on windows, what happens if you use .exe
after the name?
Is the gopls
executable an actual executable? Is it a batch script?
When I use both gopls and gopls.exe it starts and waits for input. I even moved the exe around a few directories in my PATH to make sure it wasn't a problem. I built all the versions from source manually to an exe, and kept them all in my local Go -> bin directory.
I checked what the gopls command is calling
This is the exe it calls.
If you set config.plugins.lsp.log_server_stderr = true
, do you get more output?
I set it like this
Ooh! It looks like it works now!
What I changed was, I switched back from go 1.22.5 to go 1.20.14. gopls warns me about it as well. I'm not sure if that was what made it all work, but it seems to work ok now...
I'll test again with Go 1.22.5 when I get the chance.
Hello, I've built gopls from scratch and installed lite-xl-lsp as described in the repo. It doesn't seem to be working for me. Running 'gopls' from my cmd starts it up. So that seems to be it.
I have this in my init.lua " local lspconfig = require "plugins.lsp.config" lspconfig.gopls.setup() "
I have not added anything to my config.lua in lsp
OS := Windows 10 LTSB 64 Bit Lite-Xl Version:= 2.1.1