script to syncronize remote to local of a particular f-type

Advertisement

jdawes
Joined:
Posts:
1
Location:
Australia

script to syncronize remote to local of a particular f-type

I use a winxp machine with winscp gui to connect to a fedora machine. On the remote there are hundreds of folders and sub folders. I would like a way to sync all of the .tar.gz or .mysql files on the remote to a folder on my local xp machine.

Have read about scripting and understand that this is how this would be done but i dont know what to put in the script exactly and then how to run that script from xp.

script is eg:

open user:pass@host
option batch on
option confirm off
option synchdelete off
option transfer automatic
option include *.mysql
synchronize local D:\backup /home/httpd/vhosts


is that correct?

Reply with quote

Advertisement

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

Re: script to syncronize remote to local of a particular f-type

Look fine. Just save it to file and pass it to WinSCP with command like:
winscp3.exe /console /script=script.txt
If you want to synchronize mysql file even in subdirectories, you need to allow that with:
option include "*.mysql; */"

Reply with quote

Advertisement

You can post new topics in this forum