added note for Write-Output func

This commit is contained in:
2023-10-05 13:39:07 -04:00
parent 72445c1701
commit bb18c3436d
+3
View File
@@ -54,6 +54,9 @@ Function Setup-LogFile {
}
# Log a message to the log file
# IMPORTANT: In Powershell 'echo' is an alias for Write-Output, which is overriden when this Tools.ps1 file is called before your script.
# To prevent unwanted behavior, if you need to echo something do the following instead:
# Start-Process "cmd.exe" -ArgumentList '/C echo y | some-command'
Function Write-Output {
param([Parameter(Mandatory=$true,ValueFromPipeline=$true)][string]$Message)
$Timestamp = Get-Date -Format "yyyy-MM-dd HH:mm:ss"