PowerShell Continuously printing directories compared
While using Winscp script for synchronization, command window continuously prints what is being compared like:
But in powershell scripting it prints comparing... and than prints last directory compared.
I tried to output as follows but did not help
Is it possible to monitor what is being synchronized continuously?
Comparing... Local 'D:\backup\dir1' <= Remote '/home/user/dir1' Local 'D:\backup\dir2' <= Remote '/home/user/dir2' ....
But in powershell scripting it prints comparing... and than prints last directory compared.
I tried to output as follows but did not help
function OutputDataReceived{ param($e) Write-Host $e } $session.add_OutputDataReceived( { OutputDataReceived($_) } )
Is it possible to monitor what is being synchronized continuously?