You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> Starting with Visual Studio 15.8 Preview 3, support for the common Language Server Protocol is built into Visual Studio. If you've built LSP extensions using our preview [Language Server Client VSIX](https://marketplace.visualstudio.com/items?itemName=vsext.LanguageServerClientPreview) version, they will stop working once to you've upgraded to 15.8 Preview 3 or higher. You will need to do the following to get your LSP extensions working again:
86
+
> Starting with Visual Studio 15.8 Preview 3, support for the common Language Server Protocol is built into Visual Studio. If you've built LSP extensions using our preview [Language Server Client VSIX](https://marketplace.visualstudio.com/items?itemName=vsext.LanguageServerClientPreview) version, they will stop working once to you've upgraded to 15.8 Preview 3 or higher. You will need to do the following to get your LSP extensions working again:
87
87
>
88
-
> 1. Uninstall the Microsoft Visual Studio Language Server Protocol Preview VSIX. Starting with 15.8 Preview 4, every time you perform an upgrade in Visual Studio, we will automatically detect and remove the preview VSIX for you during the upgrade process.
88
+
> 1. Uninstall the Microsoft Visual Studio Language Server Protocol Preview VSIX. Starting with 15.8 Preview 4, every time you perform an upgrade in Visual Studio, we will automatically detect and remove the preview VSIX for you during the upgrade process.
89
89
>
90
90
> 2. Update your Nuget reference to the latest non-preview version for [LSP packages](https://www.nuget.org/packages/Microsoft.VisualStudio.LanguageServer.Client).
91
91
>
@@ -123,10 +123,10 @@ The LSP does not include specification on how to provide text colorization for l
123
123
124
124
4. Create a *.pkgdef* file and add a line similar to this:
125
125
126
-
```xml
127
-
[$RootKey$\TextMate\Repositories]
128
-
"MyLang"="$PackageFolder$\Grammars"
129
-
```
126
+
```xml
127
+
[$RootKey$\TextMate\Repositories]
128
+
"MyLang"="$PackageFolder$\Grammars"
129
+
```
130
130
131
131
5. Right-click on the files and select **Properties**. Change the **Build** action to **Content** and the **Include in VSIX** property to true.
132
132
@@ -286,31 +286,31 @@ Follow these steps below to add support for settings to your LSP language servic
286
286
287
287
1. Add a JSON file (for example, *MockLanguageExtensionSettings.json*) in your project that contains the settings and their default values. For example:
288
288
289
-
```json
290
-
{
291
-
"foo.maxNumberOfProblems": -1
292
-
}
293
-
```
289
+
```json
290
+
{
291
+
"foo.maxNumberOfProblems": -1
292
+
}
293
+
```
294
294
2. Right-click on the JSON file and select **Properties**. Change the **Build** action to "Content" and the "Include in VSIX' property to true.
295
295
296
296
3. Implement ConfigurationSections and return the list of prefixes for the settings defined in the JSON file (In Visual Studio Code, this would map to the configuration section name in package.json):
297
297
298
-
```csharp
299
-
publicIEnumerable<string>ConfigurationSections
300
-
{
301
-
get
302
-
{
303
-
yieldreturn"foo";
304
-
}
305
-
}
306
-
```
298
+
```csharp
299
+
public IEnumerable<string> ConfigurationSections
300
+
{
301
+
get
302
+
{
303
+
yield return "foo";
304
+
}
305
+
}
306
+
```
307
307
308
308
4. Add a .pkgdef file to the project (add new text file and change the file extension to .pkgdef). The pkgdef file should contain this info:
@@ -334,13 +334,13 @@ Follow these steps below to add support for settings to your LSP language servic
334
334
2. User adds a file in the *.vs* folder called *VSWorkspaceSettings.json*.
335
335
3. User adds a line to the *VSWorkspaceSettings.json* file for a setting the server provides. For example:
336
336
337
-
```json
338
-
{
339
-
"foo.maxNumberOfProblems": 10
340
-
}
341
-
```
342
-
### Enabling diagnostics tracing
343
-
Diagnostics tracing can be enabled to output all messages between the client and server, which can be useful when debugging issues. To enable diagnostic tracing, do the following:
337
+
```json
338
+
{
339
+
"foo.maxNumberOfProblems": 10
340
+
}
341
+
```
342
+
### Enabling diagnostics tracing
343
+
Diagnostics tracing can be enabled to output all messages between the client and server, which can be useful when debugging issues. To enable diagnostic tracing, do the following:
344
344
345
345
4. Open or create the workspace settings file *VSWorkspaceSettings.json* (see "User editing of settings for a workspace").
346
346
5. Add the following line in the settings json file:
@@ -356,7 +356,7 @@ There are three possible values for trace verbosity:
356
356
* "Messages": tracing turned on but only method name and response ID are traced.
357
357
* "Verbose": tracing turned on; the entire rpc message is traced.
358
358
359
-
When tracing is turned on the content is written to a file in the *%temp%\VisualStudio\LSP* directory. The log follows the naming format *[LanguageClientName]-[Datetime Stamp].log*. Currently, tracing can only be enabled for open folder scenarios. Opening a single file to activate a language server does not have diagnostics tracing support.
359
+
When tracing is turned on the content is written to a file in the *%temp%\VisualStudio\LSP* directory. The log follows the naming format *[LanguageClientName]-[Datetime Stamp].log*. Currently, tracing can only be enabled for open folder scenarios. Opening a single file to activate a language server does not have diagnostics tracing support.
360
360
361
361
### Custom messages
362
362
@@ -419,7 +419,7 @@ internal class MockCustomLanguageClient : MockLanguageClient, ILanguageClientCus
0 commit comments