]> git.lizzy.rs Git - rust.git/blobdiff - editors/code/package.json
Add **Copy Run Command Line** command for vscode
[rust.git] / editors / code / package.json
index ad01fea7b6ca16d0489b7d079d9f0dd9c479ce6c..55825456ec55fb15642d7ab201073a4cf2380277 100644 (file)
                 "title": "Show Syntax Tree",
                 "category": "Rust Analyzer"
             },
+            {
+                "command": "rust-analyzer.viewHir",
+                "title": "View Hir",
+                "category": "Rust Analyzer"
+            },
             {
                 "command": "rust-analyzer.expandMacro",
                 "title": "Expand macro recursively",
                 "title": "Run",
                 "category": "Rust Analyzer"
             },
+            {
+                "command": "rust-analyzer.copyRunCommandLine",
+                "title": "Copy Run Command Line",
+                "category": "Rust Analyzer"
+            },
             {
                 "command": "rust-analyzer.debug",
                 "title": "Debug",
                         }
                     ],
                     "default": null,
-                    "description": "Environment variables passed to the runnable launched using `Test ` or `Debug` lens or `rust-analyzer.run` command."
+                    "markdownDescription": "Environment variables passed to the runnable launched using `Test` or `Debug` lens or `rust-analyzer.run` command."
                 },
                 "rust-analyzer.inlayHints.enable": {
                     "type": "boolean",
                     "default": true,
-                    "description": "Whether to show inlay hints"
+                    "description": "Whether to show inlay hints."
                 },
                 "rust-analyzer.updates.channel": {
                     "type": "string",
                     ],
                     "default": "stable",
                     "markdownEnumDescriptions": [
-                        "`\"stable\"` updates are shipped weekly, they don't contain cutting-edge features from VSCode proposed APIs but have less bugs in general",
-                        "`\"nightly\"` updates are shipped daily (extension updates automatically by downloading artifacts directly from GitHub), they contain cutting-edge features and latest bug fixes. These releases help us get your feedback very quickly and speed up rust-analyzer development **drastically**"
+                        "`stable` updates are shipped weekly, they don't contain cutting-edge features from VSCode proposed APIs but have less bugs in general.",
+                        "`nightly` updates are shipped daily (extension updates automatically by downloading artifacts directly from GitHub), they contain cutting-edge features and latest bug fixes. These releases help us get your feedback very quickly and speed up rust-analyzer development **drastically**."
                     ],
-                    "markdownDescription": "Choose `\"nightly\"` updates to get the latest features and bug fixes every day. While `\"stable\"` releases occur weekly and don't contain cutting-edge features from VSCode proposed APIs"
+                    "markdownDescription": "Choose `nightly` updates to get the latest features and bug fixes every day. While `stable` releases occur weekly and don't contain cutting-edge features from VSCode proposed APIs."
                 },
                 "rust-analyzer.updates.askBeforeDownload": {
                     "type": "boolean",
                     "default": true,
-                    "description": "Whether to ask for permission before downloading any files from the Internet"
+                    "description": "Whether to ask for permission before downloading any files from the Internet."
                 },
-                "rust-analyzer.serverPath": {
+                "rust-analyzer.server.path": {
                     "type": [
                         "null",
                         "string"
                     ],
                     "default": null,
-                    "description": "Path to rust-analyzer executable (points to bundled binary by default). If this is set, then \"rust-analyzer.updates.channel\" setting is not used"
+                    "markdownDescription": "Path to rust-analyzer executable (points to bundled binary by default). If this is set, then `#rust-analyzer.updates.channel#` setting is not used"
+                },
+                "rust-analyzer.server.extraEnv": {
+                    "type": [
+                        "null",
+                        "object"
+                    ],
+                    "default": null,
+                    "markdownDescription": "Extra environment variables that will be passed to the rust-analyzer executable. Useful for passing e.g. `RA_LOG` for debugging."
                 },
                 "rust-analyzer.trace.server": {
                     "type": "string",
                         "Full log"
                     ],
                     "default": "off",
-                    "description": "Trace requests to the rust-analyzer (this is usually overly verbose and not recommended for regular users)"
+                    "description": "Trace requests to the rust-analyzer (this is usually overly verbose and not recommended for regular users)."
                 },
                 "rust-analyzer.trace.extension": {
-                    "description": "Enable logging of VS Code extensions itself",
+                    "description": "Enable logging of VS Code extensions itself.",
                     "type": "boolean",
                     "default": false
                 },
                     }
                 },
                 "rust-analyzer.debug.openDebugPane": {
-                    "description": "Whether to open up the Debug Pane on debugging start.",
+                    "markdownDescription": "Whether to open up the `Debug Panel` on debugging start.",
                     "type": "boolean",
                     "default": false
                 },
                 "rust-analyzer.debug.engineSettings": {
                     "type": "object",
                     "default": {},
-                    "description": "Optional settings passed to the debug engine. Example:\n{ \"lldb\": { \"terminal\":\"external\"} }"
+                    "markdownDescription": "Optional settings passed to the debug engine. Example: `{ \"lldb\": { \"terminal\":\"external\"} }`"
                 },
-                "rust-analyzer.assist.importMergeBehaviour": {
+                "$generated-start": false,
+                "rust-analyzer.assist.importMergeBehavior": {
                     "markdownDescription": "The strategy to use when inserting new imports or merging imports.",
                     "default": "full",
                     "type": "string",
                     ],
                     "enumDescriptions": [
                         "Insert import paths relative to the current module, using up to one `super` prefix if the parent module contains the requested item.",
-                        "Prefix all import paths with `self` if they don't begin with `self`, `super`, `crate` or a crate name",
+                        "Prefix all import paths with `self` if they don't begin with `self`, `super`, `crate` or a crate name.",
                         "Force import paths to be absolute by always starting them with `crate` or the crate name they refer to."
                     ]
                 },
                     "type": "boolean"
                 },
                 "rust-analyzer.cargo.autoreload": {
-                    "markdownDescription": "Automatically refresh project info via `cargo metadata` on Cargo.toml changes.",
+                    "markdownDescription": "Automatically refresh project info via `cargo metadata` on `Cargo.toml` changes.",
                     "default": true,
                     "type": "boolean"
                 },
                 "rust-analyzer.cargo.allFeatures": {
-                    "markdownDescription": "Activate all available features.",
+                    "markdownDescription": "Activate all available features (`--all-features`).",
                     "default": false,
                     "type": "boolean"
                 },
                     "type": "boolean"
                 },
                 "rust-analyzer.checkOnSave.allFeatures": {
-                    "markdownDescription": "Check with all features (will be passed as `--all-features`). Defaults to `rust-analyzer.cargo.allFeatures`.",
+                    "markdownDescription": "Check with all features (`--all-features`). Defaults to `#rust-analyzer.cargo.allFeatures#`.",
                     "default": null,
                     "type": [
                         "null",
                     ]
                 },
                 "rust-analyzer.checkOnSave.allTargets": {
-                    "markdownDescription": "Check all targets and tests (will be passed as `--all-targets`).",
+                    "markdownDescription": "Check all targets and tests (`--all-targets`).",
                     "default": true,
                     "type": "boolean"
                 },
                     ]
                 },
                 "rust-analyzer.checkOnSave.target": {
-                    "markdownDescription": "Check for a specific target. Defaults to `rust-analyzer.cargo.target`.",
+                    "markdownDescription": "Check for a specific target. Defaults to `#rust-analyzer.cargo.target#`.",
                     "default": null,
                     "type": [
                         "null",
                     }
                 },
                 "rust-analyzer.checkOnSave.features": {
-                    "markdownDescription": "List of features to activate. Defaults to `rust-analyzer.cargo.features`.",
+                    "markdownDescription": "List of features to activate. Defaults to `#rust-analyzer.cargo.features#`.",
                     "default": null,
                     "type": [
                         "null",
                     "type": "boolean"
                 },
                 "rust-analyzer.completion.autoimport.enable": {
-                    "markdownDescription": "Toggles the additional completions that automatically add imports when completed. Note that your client have to specify the `additionalTextEdits` LSP client capability to truly have this feature enabled.",
+                    "markdownDescription": "Toggles the additional completions that automatically add imports when completed. Note that your client must specify the `additionalTextEdits` LSP client capability to truly have this feature enabled.",
                     "default": true,
                     "type": "boolean"
                 },
                     "uniqueItems": true
                 },
                 "rust-analyzer.diagnostics.warningsAsHint": {
-                    "markdownDescription": "List of warnings that should be displayed with info severity.\\nThe warnings will be indicated by a blue squiggly underline in code and a blue icon in the problems panel.",
+                    "markdownDescription": "List of warnings that should be displayed with info severity.\\n\\nThe warnings will be indicated by a blue squiggly underline in code and a blue icon in the `Problems Panel`.",
                     "default": [],
                     "type": "array",
                     "items": {
                     }
                 },
                 "rust-analyzer.diagnostics.warningsAsInfo": {
-                    "markdownDescription": "List of warnings that should be displayed with hint severity.\\nThe warnings will be indicated by faded text or three dots in code and will not show up in the problems panel.",
+                    "markdownDescription": "List of warnings that should be displayed with hint severity.\\n\\nThe warnings will be indicated by faded text or three dots in code and will not show up in the `Problems Panel`.",
                     "default": [],
                     "type": "array",
                     "items": {
                     "default": "client",
                     "type": "string"
                 },
+                "rust-analyzer.files.excludeDirs": {
+                    "markdownDescription": "These directories will be ignored by rust-analyzer.",
+                    "default": [],
+                    "type": "array",
+                    "items": {
+                        "type": "string"
+                    }
+                },
                 "rust-analyzer.hoverActions.debug": {
                     "markdownDescription": "Whether to show `Debug` action. Only applies when `#rust-analyzer.hoverActions.enable#` is set.",
                     "default": true,
                     "type": "boolean"
                 },
                 "rust-analyzer.inlayHints.maxLength": {
-                    "markdownDescription": "Maximum length for inlay hints.",
+                    "markdownDescription": "Maximum length for inlay hints. Default is unlimited.",
                     "default": null,
                     "type": [
                         "null",
                     "default": false,
                     "type": "boolean"
                 },
+                "rust-analyzer.lens.references": {
+                    "markdownDescription": "Whether to show `References` lens. Only applies when `#rust-analyzer.lens.enable#` is set.",
+                    "default": false,
+                    "type": "boolean"
+                },
                 "rust-analyzer.linkedProjects": {
-                    "markdownDescription": "Disable project auto-discovery in favor of explicitly specified set of projects.  \\nElements must be paths pointing to Cargo.toml, rust-project.json, or JSON objects in rust-project.json format.",
+                    "markdownDescription": "Disable project auto-discovery in favor of explicitly specified set of projects.\\n\\nElements must be paths pointing to `Cargo.toml`, `rust-project.json`, or JSON objects in `rust-project.json` format.",
                     "default": [],
                     "type": "array",
                     "items": {
                     }
                 },
                 "rust-analyzer.lruCapacity": {
-                    "markdownDescription": "Number of syntax trees rust-analyzer keeps in memory.",
+                    "markdownDescription": "Number of syntax trees rust-analyzer keeps in memory. Defaults to 128.",
                     "default": null,
                     "type": [
                         "null",
                     "type": "boolean"
                 },
                 "rust-analyzer.procMacro.enable": {
-                    "markdownDescription": "Enable Proc macro support, cargo.loadOutDirsFromCheck must be enabled.",
+                    "markdownDescription": "Enable Proc macro support, `#rust-analyzer.cargo.loadOutDirsFromCheck#` must be enabled.",
                     "default": false,
                     "type": "boolean"
                 },
+                "rust-analyzer.procMacro.server": {
+                    "markdownDescription": "Internal config, path to proc-macro server executable (typically, this is rust-analyzer itself, but we override this in tests).",
+                    "default": null,
+                    "type": [
+                        "null",
+                        "string"
+                    ]
+                },
                 "rust-analyzer.runnables.overrideCargo": {
                     "markdownDescription": "Command to be executed instead of 'cargo' for runnables.",
                     "default": null,
                     ]
                 },
                 "rust-analyzer.runnables.cargoExtraArgs": {
-                    "markdownDescription": "Additional arguments to be passed to cargo for runnables such as tests or binaries.\\nFor example, it may be '--release'.",
+                    "markdownDescription": "Additional arguments to be passed to cargo for runnables such as tests or binaries.\\nFor example, it may be `--release`.",
                     "default": [],
                     "type": "array",
                     "items": {
                     ]
                 },
                 "rust-analyzer.rustfmt.extraArgs": {
-                    "markdownDescription": "Additional arguments to rustfmt.",
+                    "markdownDescription": "Additional arguments to `rustfmt`.",
                     "default": [],
                     "type": "array",
                     "items": {
                     "items": {
                         "type": "string"
                     }
-                }
+                },
+                "$generated-end": false
             }
         },
         "problemPatterns": [
             }
         ],
         "grammars": [
-            {
-                "language": "rust",
-                "scopeName": "source.rust",
-                "path": "rust.tmGrammar.json"
-            },
             {
                 "language": "ra_syntax_tree",
                 "scopeName": "source.ra_syntax_tree",
             {
                 "id": "formatSpecifier",
                 "description": "Style for {} placeholders in format strings"
+            },
+            {
+                "id": "punctuation",
+                "description": "generic punctuation"
+            },
+            {
+                "id": "parenthesis",
+                "description": "( or )",
+                "superType": "punctuation"
+            },
+            {
+                "id": "bracket",
+                "description": "[ or ]",
+                "superType": "punctuation"
+            },
+            {
+                "id": "brace",
+                "description": "{ or }",
+                "superType": "punctuation"
+            },
+            {
+                "id": "angle",
+                "description": "< or >",
+                "superType": "punctuation"
+            },
+            {
+                "id": "comma",
+                "description": ",",
+                "superType": "punctuation"
+            },
+            {
+                "id": "colon",
+                "description": ":",
+                "superType": "punctuation"
+            },
+            {
+                "id": "semicolon",
+                "description": ";",
+                "superType": "punctuation"
+            },
+            {
+                "id": "dot",
+                "description": ".",
+                "superType": "punctuation"
             }
         ],
         "semanticTokenModifiers": [
                     "command": "rust-analyzer.syntaxTree",
                     "when": "inRustProject"
                 },
+                {
+                    "command": "rust-analyzer.viewHir",
+                    "when": "inRustProject"
+                },
                 {
                     "command": "rust-analyzer.expandMacro",
                     "when": "inRustProject"