Related: #6680
One use case for Export-FormatData - even though about_Format.ps1xml doesn't currently mention it - is to use existing formatting definitions as a starting point for creating new ones.
To that end, outputting pretty-printed XML would be much more convenient - currently, a single-line XML string is output.
Environment data
Written as of:
Related: #6680
One use case for
Export-FormatData- even thoughabout_Format.ps1xmldoesn't currently mention it - is to use existing formatting definitions as a starting point for creating new ones.To that end, outputting pretty-printed XML would be much more convenient - currently, a single-line XML string is output.
If changing the existing behavior is not a backward-compatibility concern:
Otherwise:
-Format(or, to follow the - inverted - logic ofConvertTo-Json, perhaps-Uncompress?) that results in pretty-printed output.Environment data
Written as of:
PowerShell Core v6.0.2