Warning: This project is no longer in active development Use the Grafana Labs maintained tool instead: https://github.com/grafana/jsonnet-language-server.
A Language Server Protocol (LSP) server for Jsonnet.
jsonnet-language-server-demo.mp4
- Jump to definition
- For local variables, import and importstr files, and index targets.
- Workspace symbols
- Return a hierarchy of document symbols representing all desugared nodes of the Jsonnet AST.
- Diagnostics
- Static errors and warnings of runtime errors.
- Formatting
- Format document according to default options.
Refer to example.jsonnet for a documented walkthrough.
To install the LSP server with Go into “${GOPATH}”/bin:
go get -u github.com/jdbaldry/jsonnet-language-server
To download the latest release binary from GitHub:
curl -Lo jsonnet-language-server https://github.com/jdbaldry/jsonnet-language-server/releases/latest/download/jsonnet-language-server
Contributions are more than welcome and I will try my best to be prompt with reviews.
Individual commits should be meaningful and have useful commit messages. For tips on writing commit messages, refer to How to write a commit message. Contributions will be rebased before merge to ensure a fast-forward merge.
Contributors must sign the DCO for their contributions to be accepted.
Go code should be formatted with gofmt
and linted with golangci-lint.
Refer to editor/jsonnet-language-server.el for an example of enabling the LSP server with lsp-mode.
VSCodium / VSCode
Use the vscode-jsonnet extension