Skip to content

Latest commit

 

History

History
37 lines (31 loc) · 1.59 KB

File metadata and controls

37 lines (31 loc) · 1.59 KB

WebDSL VS Code Extension

Quick developer instructions.

Dependencies:

  • a modern version of Node.js with npm
  • really, that's it

Developing WebDSL VS Code Extension

Running a development version

Install dependencies with npm i. Create a resources directory and put WebDSL LSP server JAR (webdsl-lsp-1.0.0.jar) there (the recommended way is to create a soft symlink to app/build/libs/webdsl-lsp-1.0.0.jar in your local copy of WebDSL LSP server; this way, you don't have to copy the JAR every time you rebuild the LSP server). Run by starting the "Run Extension" task from "Run and Debug" tab in VS Code.

Running a development version without rebuilding the shadow JAR

Might be useful if you want to e.g. debug the WebDSL LSP server. Start the development version of the server on a fixed port (e.g. 1337). Replace the following line in function activate in extension.ts:

const port = await spawnLanguageServer(context);

with:

const port = 1337;

Then, run the extension as described above.

Building and installing a packaged extension

Install the vsce tool globally on your machine (npm i -g @vscode/vsce). Then, run vsce package --skip-license - webdslvscodeplugin-0.0.1.vsix should be created. To install the extension from this package, run {code,codium} --install-extension webdslvscodeplugin-0.0.1.vsix.

Seeing debug output from the extension

This should include any errors generated by the LSP server. Go to OUTPUT tab of the terminal dock (open with ctrl+shift+). Select webdslLanguageclientoutput. SelectDebug` log level (using the gearbox icon).