Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Helix GOPLS Configuration Out of Date #3905

Open
brycefisher opened this issue Mar 31, 2024 · 3 comments
Open

Helix GOPLS Configuration Out of Date #3905

brycefisher opened this issue Mar 31, 2024 · 3 comments

Comments

@brycefisher
Copy link

What version of rules_go are you using?

N/A

What version of gazelle are you using?

N/A

What version of Bazel are you using?

N/A

Does this issue reproduce with the latest releases of all the above?

Yes

What operating system and processor architecture are you using?

MacOS M1 / armv7

Any other potentially useful information about your toolchain?

N.A

What did you do?

I followed the directions in the Wiki for configuring Bazel IDE in helix via GOPLS:
https://github.com/bazelbuild/rules_go/wiki/Editor-setup#helix-editor

What did you expect to see?

The helix editor to start normally and LSP features working

What did you see instead?

Failed to parse language config: unknown field `config`, expected one of `name`, `language-id`, `scope`, `file-types`, `shebangs`, `roots`, `comment-token`, `comment-tokens`, `block-comment-tokens`, `text-width`, `soft-wrap`, `auto-format`, `formatter`, `diagnostic-severity`, `grammar`, `injection-regex`, `language-servers`, `indent`, `debugger`, `auto-pairs`, `rulers`, `workspace-lsp-roots`, `persistent-diagnostic-sources`
in `language`

Press <ENTER> to continue with default language config

Updated COnfig that works for me

version - helix 24.3 (2cadec0b)

[language-server.gopls]
command = "gopls"
environment = { "GOPACKAGESDRIVER" = "./tools/bazel/gopackagesdriver.sh" }

[[language]]
name = "go"
file-types = ["go"]
language-servers = ["gopls"]
@theletterjeff
Copy link

Were you able to add the extra args included in the current wiki page, e.g., gofumpt, staticcheck, usePlaceholders, etc.? If so, you could edit the wiki page with this solution and close this issue.

@brycefisher
Copy link
Author

I wasn't able to add the additional args but I can try to figure it out and post in this issue.

As far as I know, I don't have edit rights for the wiki.

@brycefisher
Copy link
Author

I think perhaps the script referenced is meant to set whatever arguments are needed by gopls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants