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
In #6691 we made that Export-FormatData returns pretty-printing XML output by default as requested in #6681.
Users may need a different output: -AsXML - output [xml] object -AsXMLString or -AsString - output compact XML string without formatting. -Encoding - set encoding of output file .
And perhaps add option to output to pipe not file and -PassThru.
Export commands don't typically return data. Perhaps Get-FormatData would be better for returning an [xml] object? Just curious - why the request for compact XML ? Is the formatted stuff that much bigger? Adding -encoding to match, for example export-csv, makes sense.
For me, it's not so much about having a compression/compact option, but having a way to revert behavior. I'm not a big fan of changing output behavior in such a way that increases resource consumption without a way to revert the behavior if change was not fixing a broken behavior and implementing the previous behavior is simple enough.
Activity
BrucePay commentedon Apr 22, 2018
Exportcommands don't typically return data. PerhapsGet-FormatDatawould be better for returning an[xml]object? Just curious - why the request for compact XML ? Is the formatted stuff that much bigger? Adding-encodingto match, for exampleexport-csv, makes sense.iSazonov commentedon Apr 23, 2018
Mark Kraus (@markekraus) requested this in #6691.
markekraus commentedon Apr 23, 2018
For me, it's not so much about having a compression/compact option, but having a way to revert behavior. I'm not a big fan of changing output behavior in such a way that increases resource consumption without a way to revert the behavior if change was not fixing a broken behavior and implementing the previous behavior is simple enough.