Add here-string autoClosingPairs to PowerShell language configuration#5545
Draft
Copilot wants to merge 2 commits into
Draft
Add here-string autoClosingPairs to PowerShell language configuration#5545Copilot wants to merge 2 commits into
Copilot wants to merge 2 commits into
Conversation
Closes #1517 VS Code PR microsoft/vscode#95245 added autoclosing pairs for PowerShell here-strings to VS Code's built-in language configuration. This change explicitly adds the same pairs to the extension's setLanguageConfiguration call so the behavior is self-documenting and works correctly regardless of the VS Code version.
Copilot
AI
changed the title
[WIP] Fix here string intellisense completion and indentation
Add here-string autoClosingPairs to PowerShell language configuration
Jun 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PowerShell here-strings (
@'...'@,@"..."@) were not auto-closed by the editor — typing@"would not insert the closing"@on a new line.This was fixed upstream in VS Code core via microsoft/vscode#95245, which added here-string entries to the built-in PowerShell
language-configuration.json. This PR mirrors that fix explicitly in the extension'ssetLanguageConfigurationcall so the behavior is self-documenting and not silently dependent on the VS Code version.Changes
src/extension.ts: AddsautoClosingPairsto thesetLanguageConfigurationcall, including:@'→\n'@and@"→\n"@withnotIn: ["string", "comment"]— matches the VS Code core fix exactly;\nis required because PowerShell's here-string terminator must be at the start of a line{},[],(),"",'',<##>) carried forward explicitly, since specifyingautoClosingPairsreplaces rather than merges with the built-in configuration