Created
August 28, 2015 03:50
-
-
Save taisyo7333/10420317266fee6e3365 to your computer and use it in GitHub Desktop.
powershell : tee error
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Write-ErrorLog { | |
param( $file_name , $message ) | |
Write-Error $message 2>&1 | Tee-Object -FilePath $file_name -Append | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment