Skip to content

Installation

To get started with Contextive you need to install our extension/plugin into your IDE. There are two primary ways:

  1. As an IDE Plugin/Extension
  2. As a Language Server in an IDE with LSP Support

IDE Plugins/Extensions

For the following IDEs, Contextive can be installed via their plugin/extensions marketplaces.

Visual Studio Code

Open Visual Studio Code, launch the quick open (Ctrl+P) and then enter ext install devcycles.contextive. OR, search contextive in the extensions side-bar.

Visit the Contextive Extension on the VsCode Marketplace for details.

Check the extension README for usage instructions.

IntelliJ Plugin Platform

Open your JetBrains product, e.g. IntelliJ IDEA, or JetBrains Rider, open the Settings dialog and choose “Plugins”. Search contextive in the Marketplace tab and click the Install button.

See JetBrains documentation on installing plugins, and visit the Contextive Plugin on the JetBrains Marketplace for details.

Check the plugin README for usage instructions, known issues and links to related JetBrains issues with the Language Server Protocol support.

Visual Studio 2022

Open Visual Studio 2022. Use the Extensions -> Manage Extensions... menu option. Search for Contextive and click Install.

Neovim

For Neovim, the Contextive Language Server can be installed via Mason by executing the Mason install command in Neovim.

:MasonInstall contextive

Alternatively, install manually as described below.

The following configuration requires the neovim/nvim-lspconfig plugin, which can be installed and set up by following this install guide.

Use lspconfig to setup and initialize the Contextive Language Server configuration. The following lua snippet needs to be included in the init.lua file either directly or from another lua module like lspconfigs.lua.

local lspconfig = require("lspconfig")
lspconfig.contextive.setup {}

The workspace root will be the first parent folder containing .contextive or .git.

For more information on configuring Neovim with Lua modules, see: https://neovim.io/doc/user/lua-guide.html#lua-guide-config

Manually Installing the Language Server

For the following IDEs, you will need to install the Contextive Language Server and then configure the IDE to use it.

IDE-specific Configuration

As discussed in setting up glossaries, Contextive will scan the workspace starting at the workspace root for files that match the pattern *.glossary.yml.

Consult your IDE’s documentation on how it determines the workspace root - e.g. some look for a .git folder, others depend on how you open the workspace.

Helix

For Helix, install the Contextive Language Server manually as described below.

Then add the following configuration to ~/.config/helix/languages.toml:

[language-server.contextive]
command = "Contextive.LanguageServer"

Once Contextive is defined as a language sever, it can be added to specific languages, e.g.:

[[language]]
name = "typescript"
language-servers = [ { name = "typescript-language-server" }, { name = "contextive" } ]

See the helix language configuration for more details, including the roots setting which may be needed for non-standard workspace roots.

See this discussion for enabling LSP servers in all files.

Others

Official support for other IDEs coming soon!

In the meantime, if your IDE supports the Language Server Protocol (LSP) try downloading the Contextive Language Server as described below and consult your IDE documentation for how to configure a language server.

If you get it working, we’d love you to submit a PR to this README with instructions on how to get it working your favourite IDE.

Installing Contextive Language Server

  1. Download the appropriate zip file for your operating system and architecture:

    Terminal window
    curl -L https://github.com/dev-cycles/contextive/releases/download/<version>/Contextive.LanguageServer-<os>-<arch>-<version>.zip -o Contextive.LanguageServer-<os>-<arch>-<version>.zip

    OR, manually download the language server asset from the Github Release.

  2. Unzip the Contextive.LanguageServer and copy the file into a folder that is included in your system’s PATH:

    Assuming the $HOME/bin directory has been created beforehand and is included in the system’s PATH.

    Terminal window
    unzip Contextive.LanguageServer-<os>-<arch>-<version>.zip -d contextive-language-server
    cp contextive-language-server/Contextive.LanguageServer $HOME/bin
  3. Verify that Contextive.LanguageServer is found in the PATH. A non-zero exit code indicates that the language server was not found in the PATH:

    Terminal window
    command -v Contextive.LanguageServer

    The command should return the absolute path to the binary if it’s found in the system PATH.

  4. For IDEs in the officially supported list, check the configuration guides above. Otherwise, consult your IDE’s Language Server documentation for details on how to configure a new language server and enable it for all files.