ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

LSP-rust-analyzer

by sublimelsp ST4

Convenience package for rust-analyzer

Details

Installs

  • Total 5K
  • Win 2K
  • Mac 2K
  • Linux 2K
Dec 8 Dec 7 Dec 6 Dec 5 Dec 4 Dec 3 Dec 2 Dec 1 Nov 30 Nov 29 Nov 28 Nov 27 Nov 26 Nov 25 Nov 24 Nov 23 Nov 22 Nov 21 Nov 20 Nov 19 Nov 18 Nov 17 Nov 16 Nov 15 Nov 14 Nov 13 Nov 12 Nov 11 Nov 10 Nov 9 Nov 8 Nov 7 Nov 6 Nov 5 Nov 4 Nov 3 Nov 2 Nov 1 Oct 31 Oct 30 Oct 29 Oct 28 Oct 27 Oct 26 Oct 25 Oct 24
Windows 2 8 2 4 3 4 6 14 6 8 7 3 9 4 12 5 6 2 4 4 5 6 7 2 7 5 6 4 4 5 4 10 13 10 3 5 3 12 5 2 2 8 4 1 7 3
Mac 2 4 8 7 7 6 7 5 13 2 6 5 1 8 5 2 12 6 6 6 2 4 3 2 4 5 6 7 7 5 7 7 3 6 3 7 3 5 7 0 8 3 7 5 1 7
Linux 1 4 9 7 10 9 9 7 5 6 5 6 6 7 2 9 9 13 5 6 5 7 4 7 8 8 6 10 11 11 1 8 2 9 5 3 5 10 12 10 10 3 4 8 13 7

Readme

Source
raw.​githubusercontent.​com

LSP-rust-analyzer

This is a helper package that starts the rust-analyzer language server for you.

Installation

  1. Install LSP via Package Control.
  2. Install LSP-rust-analyzer via Package Control.
  3. (Recommended) Install the LSP-file-watcher-chokidar via Package Control to enable functionality to notify the server about changed files.

Configuration

You can edit the global settings by opening the Preferences: LSP-rust-analyzer Settings from the Command Palette.

You can also have a project-specific configuration. Run the Project: Edit Project from the Command Palette and edit the following in the settings object.

{
    // folders: [
    //   ...
    // ]
    "settings": {
        "LSP": {
            "rust-analyzer": {
                "settings": {
                    //Setting-here
                }
            }
        }
    }
}

Applicable Selectors

This language server operates on views with the source.rust base scope.

Installation Location

The server binary is automatically downloaded to $CACHE/Package Storage/LSP-rust-analyzer.

Custom Command Palette Commands

LSP-rust-analyzer: Run…

Select a cargo command from the submenu. This spawns a shell with Terminus for tests, checks and executing code.

Note: The Terminus package needs to be installed for this functionality.

Example

LSP-rust-analyzer: Open Docs Under Cursor

Opens the URL to documentation for the symbol under the cursor, if available.

LSP-rust-analyzer: Reload Project

Reloads the project metadata, i.e. runs cargo metadata again.

LSP-rust-analyzer: Expand Macro Recursively

Shows the full macro expansion of the macro at current cursor.