ray-x / go.nvim

G'day Nvimer, Joyful Gopher: Discover the Feature-Rich Go Plugin for Neovim
MIT License
1.9k stars 119 forks source link

gopls -debug=localhost:8080 #464

Closed gonzaloserrano closed 1 month ago

gonzaloserrano commented 1 month ago

Hi!

What's the proper way to pass flags to gopls within go.nvim to enable debugging? i.e gopls -debug=localhost:8080

The goal is to troubleshoot https://github.com/golang/go/issues/66647

Thanks

ray-x commented 1 month ago

https://github.com/ray-x/go.nvim/blob/294d65c93514f14fbbe8af0545ab8918d939acdb/lua/go/lsp.lua#L215-L220

So in go.nvim config set config to

{
...
gopls_cmd = { 'gopls',  '-debug=localhost:8080'}
...
}
gonzaloserrano commented 1 month ago

Thanks!