Technique for selectively formatting data in a PowerShell pipeline and output as HTML

前端 未结 4 1780
一向
一向 2021-02-02 04:25

Say that you want to do some fancy formatting of some tabular output from powershell, and the destination is to be html (either for a webserver, or to be sent in an email). Let\

4条回答
  •  南旧
    南旧 (楼主)
    2021-02-02 05:31

    How about using JQuery, and inserting a header with the JQUery script and some styling, like:

    Get-Process | ConvertTo-Html -Head @'
    
    
    
    
    '@ | Out-File procs.html; ii .\procs.html
    

提交回复
热议问题