eo-lsp-server
v0.4.0
Published
Language Server for a syntax highlighter for the EO Language
Readme
LSP Server for EOLANG
This is the LSP server for EO.
It provides semantic highlighting and parsing error checking for .eo files
(written in EOLANG).
In order to use it, you need to have Node and npm installed.
Using with IntelliJ (with LSP4IJ)
LSP4IJ, a free LSP support plugin
for IntelliJ, provides an EO LSP server template
to automatically install and run the LSP Server for EOLANG:
- Install LSP4IJ into IntelliJ
- Open any
*.eofile, a notification will appear withInstall LSP Server for EOLANG - Click the link, confirm the server creation, then click
OK - The server will be installed (via npm)
Once done, semantic tokens and diagnostics will be available.
Using with Sublime Text
To use this LSP server with Sublime Text, you'll need to install
the LSP package and configure it
in Settings → Package Settings → LSP → Settings:
{
"clients": {
"eo-lsp": {
"enabled": true,
"command": ["npx", "-y", "[email protected]", "--stdio"],
"selector": "source.eo"
}
}
}Then, create a syntax definition file in
~/Library/Application Support/Sublime Text/Packages/User/EO.sublime-syntax:
%YAML 1.2
---
name: EO
file_extensions:
- eo
scope: source.eo
contexts:
main:
- match: '^\+[^\n]+$'
scope: meta.eo
- match: '#.*$'
scope: comment.line.eo
- match: '[@^*?]'
scope: keyword.eo
- match: '[\[\]\\>!:\.\)\(]|\+>'
scope: keyword.operator.eo
- match: '"[^"]*"'
scope: string.quoted.double.eo
- match: '\b(\+|-)?\d+(\.\d+(e(\+|-)?\d)?)?\b'
scope: constant.numeric.eoShould work. If it doesn't, file an issue, we'll help.
How to Contribute
First, install Node modules with:
npm installThen, build the project:
makeMake changes on a new branch.
You can run an instance of VS Code with the extension running by hitting F5
in the code editor.
After modifications, test your code with:
make testCreate a pull request, we'll be glad to review it and merge.
