How to Stop Propagating Unwanted Echoes in the Command Line

Advertisement

cagatay117
Joined:
Posts:
1

How to Stop Propagating Unwanted Echoes in the Command Line

I am running a batch script which calls a WinSCP script via command line. The script file has get command. When I run the script, say backup.bat, it executes and while downloading the file I can see these lines for every file:
some_file.zip      |        8894 KB | 3093,6 KB/s | binary |  52%
I don't want the WinSCP script to propagate everything going on in the script. I tried
option echo off
but it didn't work either. I only want to echo things that I wrote echo "message" in the script explicitly. I don't want to send null like this either
winscp.com /script="backup.txt" > null
What can I do?

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,441
Location:
Prague, Czechia

Re: How to Stop Propagating Unwanted Echoes in the Command Line

Currently, there's no way to prevent the file transfer progress to be printed in scripting.
If you want to filter it, you have to filter it yourself in your batch file.
Or use WinSCP .NET assembly, instead of scripting.

Reply with quote

Advertisement

You can post new topics in this forum