Skip to content

Latest commit

 

History

History
14 lines (8 loc) · 574 Bytes

File metadata and controls

14 lines (8 loc) · 574 Bytes

ConvertFrom-Csv has undocumented partial comment support

When multiple strings are fed into ConvertFrom-Csv, it will ignore lines prefixed with a # character. When fed a single string, it retains those lines. Unless it is the first line, in which case it is ignored either way.

The workaround is to use double quotes around the item with the leading #.

The script Test-1.ps1 shows the issue.