Question

According to WinSCP documentation, if the removeFiles parameter is set to true for the Session.SynchronizeDirectories method, it will deletes obsolete files.

As the documentation doesn't provide any definition of what an obsolete file is, I had to run some tests to find out what is the impact of the this parameter.

From my understanding, an obsolete file is present on the destination folder but not on the source folder. So if the removeFiles parameter is set to true, any file in the destination folder that can't be matched with a file having same name on the source folder will be deleted.

Do I have the right definition or am I missing something that could impact on the synchronization?

Was it helpful?

Solution

The answer is part of the WinSCP documentation (in the Synchronization Mode section).

Files in target directory not present in source directory are optionally deleted (enable option Delete files).

The option Delete files is probably refering to the removeFiles parameter.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top