folks,
I need to redirect command output to 2 files, in one file redirect stdout stream,
to another file redirect stderr stream.
Is it possible to do in cmd, PowerShell on windows ?
folks, I need to redirect command output to 2 files, in one file redirect
Share
For powershell
Let us say you have
my.ps1like below:You can do:
You get stdout and stderr in the corresponding files.
More on Tee-Object:
http://technet.microsoft.com/en-us/library/dd347705.aspx
More on capturing all streams:
https://connect.microsoft.com/feedback/ViewFeedback.aspx?FeedbackID=297055&SiteID=99