Skip to content

Latest commit

 

History

History
62 lines (45 loc) · 2.21 KB

README.md

File metadata and controls

62 lines (45 loc) · 2.21 KB

Langoustine VS Code extension

This is a simple VS code extension intended for people interested in writing Language Servers (LS).

It is designed to simplify development experience when working with language servers - instead of writing a dedicated VS Code extension for each, you can just configure a server for a particular file extension.

Installation

The extension is available in VS Code Marketplace under the name langoustine-vscode

Configuration

Let's assume you want to install the LLVM IR language server locally and use it for files ending with .ll

  1. First you downloaded the binary for your platform (let's say MacOS), and put it in /usr/local/bin/LLVM_LanguageServer-x86_64-apple-darwin

  2. Then you installed this VS Code extension

  3. Next you need to add a configuration into your user settings (Preferences: Open User Settings (JSON) in command palette):

    "langoustine-vscode.servers": [
      {
          "name": "LLVM LSP",
          "extension": "ll",
          "command": "/usr/local/bin/LLVM_LanguageServer-x86_64-apple-darwin"
      }
  ]

After you reload the VS Code window and open a .ll file you should have the LSP features available!

Passing arguments

Let's say your LSP command requires some arguments. For example, if you decided you want to use Langoustine Tracer, then you would configure the extension as following:

    "langoustine-vscode.servers": [
      {
          "name": "LLVM LSP",
          "extension": "ll",
          "command": "langoustine-tracer",
          "args": [
            "/usr/local/bin/LLVM_LanguageServer-x86_64-apple-darwin"
          ]
      }
  ]

Where langoustine-tracer is the path to Tracer's binary.