Remoe whitelines in file through PowerShell
In need of removing all white lines in a file quickly use the below script.
(Get-Content c:\temp\script.ps1) | ? {$_.trim() -ne ""} | Set-Content c:\temp\script.ps1
3/13/2014 Powershell 0 Comments
(Get-Content c:\temp\script.ps1) | ? {$_.trim() -ne ""} | Set-Content c:\temp\script.ps1
© Copyright 2014 AskVP - Yet another IT Admins Blabber
0 comments :