A bubbler language server for VSCode.
Powered by uni-vscode.
Quick install for VSCode: bubbler-vscode
This is a "bubbler language" vscode extension based on Antlr and Language Server Protocol. It is useful for quick parsing checks using VSCode. Semantic highlighting is the only major component implemented because static semantics computations (aka attributes) are not implemented for grammars.
The code is divided into two parts: Server and Client:
- The server (with Logger, LspHelpers, and Workspaces) is C# code that implements an LSP server.
- The client is Typescript code that implemements the client VSCode extension.
The server is a C# program that reads stdin and writes to stdout. VSCode will redirect the input and output in order to communicate with the server.
git clone https://github.com/xaxys/bubbler-vscode.git
cd bubbler-vscode
dotnet build
The grammar must be processed by the trgen (0.14.3) application of Trash. trgen
creates a standardized parser application from templates.
Recommand to use .Net5.0
cd Trgen
mkdir Generated
trgen -s proto
cd Generated
dotnet build
4. Copy the language server and the generated parser, then run the "install.sh" script to create the extesion for VSCode
The client is a thin layer of code in Typescript. The "install.sh" script builds the .vsix file which you can install.
cd VsCode
bash clean.sh && bash install.sh
code .
In VSCode, open a file (e.g., a Bubbler source file). In the lower right corner, there is a type. Change the type of the file to "Bubbler". It takes a little while, but it should colorize the source file.
- LSP server in C#.
- VSCode client code in Typescript.
- Grammars are implemented in Antlr4. The parser driver is implemented using trgen.