Keep local directory up to date script

Advertisement

ntoreax
Joined:
Posts:
15

Keep local directory up to date script

Good Day Support Team

I was trying to make a script that will keep the local directory up to date and if possible download specific file by name only. But when I run it it picks files from even other directories.
Please advise what could be the mistake.

script
option batch abort
option confirm off
open sftp://user:££££@ip:port -hostkey="ssh-ed25519 255 m4ihd5J1uHLO/rrvOc8TUiT/eWixH6YXtqAndq7asaw"
synchronize both
synchronize remote  C:\Users\axel.ntore\Desktop\file\0707\  /home/ntoreax/Documents/ILLOGSOURCE
synchronize both -filemask="|*rndps"
Attaching logs for troubleshoot.
  • logfile.log (789.8 KB, Private file)
Description: Logfile

Reply with quote

Advertisement

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

Re: Keep local directory up to date script

Maybe you could explain what those three synchronize commands are supposed to do? Which of the three do not do what you wanted?

Didn't you actually wanted to do something like this (= just one synchronize command)?
synchronize remote -filemask="|*rndps" C:\Users\axel.ntore\Desktop\file\0707\  /home/ntoreax/Documents/ILLOGSOURCE

Reply with quote

ntoreax
Joined:
Posts:
15

keep local directory up to date Script

Good Day @Martin

Thanks for your quick feedback,
the goal of this script is to keep the local directory up to date it will run every 1 hour
and copy files starting by RND... (manually to achieve it I use the steps on the shared screenshot) keep local Directory up to date)
Let me try the shared script and confirm if it actually does what I needed
synchronize remote -filemask="|*rndps" C:\Users\axel.ntore\Desktop\file\0707\ /home/ntoreax/Documents/ILLOGSOURCE
Axel N

Reply with quote

Advertisement

You can post new topics in this forum