Editor setup¶
Syntax highlighting¶
Currently, we support an extension for Visual Studio Code or VSCodium, the Free/Libre Open Source Software Binaries of VS Code.
It supports syntax highlighting and is available on:
- Elephant Specification Language on VS Code Marketplace
- Elephant Specification Language on Open-VSX marketplace for VSCodium
Tip
You can also press Ctrl+P in either editor and enter:
Sooner, rather than later, we aim to implement a fully fledged Language Server in that extension that checks your specifications for problems in real-time as you type and save. Currently, you can do the following in either of those two editors:
Define a build task¶
VSCode/VSCodium support defining build tasks. These can populate/update the PROBLEMS
tab in your
editor that typically shows any problems in your code.
First off, make sure you have a Python environment with RaESL installed, for instance by means of pip or pipx:
This should enable the raesl
command in your terminal.
Using the task below, you can update your problems with those listed in a run of the RaESL compiler. The steps to do so are:
- Make sure you have a
.vscode/
directory in your workspace and add the snippet below in atasks.json
file in that directory. - You can optionally change the
"args": ["compile", "."],
line's"."
to the path of your specification files or folder between quotes. - Press Ctrl+Shift+B to update the problems after some changes.