Reputation: 831
I am trying to update only timestamps with WinSCP. I can't find many examples online so I am asking here.
synchronize timestamps -filemask=" | *.txt; *.log" "source" "target"
I have tried this command, but I keep getting an 'unknown option' message. I have tried -timestamps
and variations of this with no luck.
Documentation doesn't have any examples. It mentions it can only work with SFTP so I am unsure if there is another parameter or switch to do that.
Upvotes: 1
Views: 331
Reputation: 202360
The timestamp synchronization functionality is not directly available in WinSCP scripting.
But you can set raw configuration option Interface\SynchronizeParams
using /rawconfig
command-line parameter:
winscp.com /script=yourscript.txt /ini=nul /rawconfig Interface\SynchronizeParams=256
Then the following command will update remote timestamps, instead of remote files:
synchronize remote -filemask=" | *.txt; *.log" "source" "target"
(analogically for local
)
Upvotes: 1