fix(lsp): add GOFLAGS environment setting to gopls

Add GOFLAGS environment setting to gopls and add the 'mage' tag so that
gopls works with magefiles.
This commit is contained in:
Dan Anglin 2023-02-13 08:15:28 +00:00
parent 3a210b1d56
commit e92cf5bdb3
Signed by: dananglin
GPG key ID: 0C1D44CFBEE68638

View file

@ -48,6 +48,9 @@ lspconfig.gopls.setup{
analyses = { analyses = {
unusedparams = true, unusedparams = true,
}, },
env = {
GOFLAGS = "-tags=mage"
},
gofumpt = true, gofumpt = true,
staticcheck = true, staticcheck = true,
}, },