vscode-powershell: Code provider folding is not folding here strings
System Details
- Operating system name and version: Windows 10 1803
- VS Code version: 1.25.0 32-bit
- PowerShell extension version: daily build with PR #1416 pulled down
- Output from
$PSVersionTable:
Name Value
---- -----
PSVersion 5.1.17134.137
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.17134.137
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
Issue Description
Code folding via the folding provider seems to be working for everything except here strings:

FWIW the npm tests fail on my dev machine:

Attached Logs
7/9/2018 9:13:36 PM [NORMAL] - Visual Studio Code v1.25.0 32-bit
7/9/2018 9:13:36 PM [NORMAL] - PowerShell Extension v1.7.0
7/9/2018 9:13:36 PM [NORMAL] - Operating System: Windows 64-bit
7/9/2018 9:13:36 PM [DIAGNOSTIC] - Succesfully required c:\Program Files (x86)\Microsoft VS Code\resources\app/node_modules.asar/vscode-textmate
7/9/2018 9:13:36 PM [DIAGNOSTIC] - Loaded the vscode-textmate module
7/9/2018 9:13:36 PM [DIAGNOSTIC] - Created the textmate Registry
7/9/2018 9:13:36 PM [DIAGNOSTIC] - PowerShell grammar file specified as c:\Program Files (x86)\Microsoft VS Code\resources\app\extensions\powershell\syntaxes\powershell.tmLanguage.json
7/9/2018 9:13:36 PM [NORMAL] - Language server starting --
7/9/2018 9:13:36 PM [NORMAL] - exe: C:\WINDOWS\Sysnative\WindowsPowerShell\v1.0\powershell.exe
7/9/2018 9:13:36 PM [NORMAL] - args: C:\Users\Keith\GitHub\rkeithhill\PowerShellEditorServices\module\PowerShellEditorServices\Start-EditorServices.ps1 -HostName 'Visual Studio Code Host' -HostProfileId 'Microsoft.VSCode' -HostVersion '1.7.0'-AdditionalModules @('PowerShellEditorServices.VSCode') -BundledModulesPath 'C:\Users\Keith\GitHub\rkeithhill\PowerShellEditorServices\module'-EnableConsoleRepl -LanguageServicePipeName LanguageService_55b445f8a3da0175246c.pipe -DebugServicePipeName DebugService_55b445f8a3da0175246c.pipe -LogLevel 'Diagnostic' -LogPath 'C:\Users\Keith\GitHub\rkeithhill\vscode-powershell\logs\1531192416-someValue.sessionId\EditorServices.log' -SessionDetailsPath 'C:\Users\Keith\GitHub\rkeithhill\vscode-powershell\sessions\PSES-VSCode-21924-436123' -FeatureFlags @()
7/9/2018 9:13:36 PM [NORMAL] - Syntax Folding Provider registered
7/9/2018 9:13:37 PM [NORMAL] - powershell.exe started, pid: 29196
7/9/2018 9:13:41 PM [NORMAL] - Language server started.
7/9/2018 9:13:41 PM [NORMAL] - {"status":"started","debugServiceTransport":"NamedPipe","languageServiceTransport":"NamedPipe","debugServicePipeName":"DebugService_55b445f8a3da0175246c.pipe","languageServicePipeName":"LanguageService_55b445f8a3da0175246c.pipe"}
7/9/2018 9:13:41 PM [NORMAL] - Connecting to language service on pipe LanguageService_55b445f8a3da0175246c.pipe...
7/9/2018 9:13:41 PM [NORMAL] - Language service connected.
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 20 (12 by maintainers)
Commits related to this issue
- (GH-1417) Add tests for CRLF documents Previously the test fixtures were failing on some Windows systems due to git changing the line endings. This commit adds a new test fixture, and runs the same ... — committed to glennsarti/vscode-powershell by glennsarti 6 years ago
- (GH-1417) Tokenize a document per line to avoid line endings Previously the folding provider would tokenize the entire document at a time. While this mostly works, it causes issues with regular expre... — committed to glennsarti/vscode-powershell by glennsarti 6 years ago
- (GH-1417) Add tests for CRLF documents Previously the test fixtures were failing on some Windows systems due to git changing the line endings. This commit adds a new test fixture, and runs the same ... — committed to glennsarti/vscode-powershell by glennsarti 6 years ago
- (GH-1417) Add folding tests for double quote here strings Previously only single quoted here strings were tested for folding. This commit adds a test for the double quoted herestrings as well. — committed to glennsarti/vscode-powershell by glennsarti 6 years ago
- (GH-1417) Fix code folding on CRLF documents (#1418) * (GH-1417) Tokenize a document per line to avoid line endings Previously the folding provider would tokenize the entire document at a time. W... — committed to PowerShell/vscode-powershell by glennsarti 6 years ago
So the test failure is on that particular piece of text. The plot thickens… AND I can repro that failure.
You may have Git configured to use LF but the repo configures itself to use
autovia* text=autoin.gitattributes. However, if you’re on Linux/macOS,autowould select LF.