So do you need any help now?
I don't have it anymore. I am not sure if session log is the one you get by adding the -log option? If it is that then it only cotained the info that SCP could not connect to the server. When I turned on debug logging there was some error code like 10004 or something like that and I found on this forum that it means that it could not connect to the server.
I think I used cmd because I did not realize there was a SCP task in ant. I can try using it later. But the behavior is rather strange so I decided to ask.
Please attach a full session log file showing the problem (using the latest version of WinSCP).
Btw, why do you run WinSCP via cmd
?
Hi,
I am running WinSCP from a command file. The command file has this content:
open ftp:user:****@ftpx.forpsi.com:21
synchronize remote .\deploy\t /www/pomroots/pom1/t
I call it from an ANT task using this command line:
c:\windows\system32\cmd /c wincp.com /script=... /log=logfile.log
Now when I do it on my Windows10 machine it works. On my Windows7 machine SCP does not connect to the server. When I try it without ANT just using the command line calling directly WinSCP.com from the OS command line, it WORKS on Windows7 too. Just it does not work when called from Ant. The exec task in ANT looks like this:
<exec dir="." executable="c:/windows/system32/cmd.exe" failonerror="true">
<arg line="/c y:\WinSCP\WinSCP.com /ini=null /script=${cmdfile} /log=${cmdfile}.log />
</exec>
On Windows10 this works, on Windows7 not.