Sync Rules help

  • Rob

    Rob - 2006-05-16

    Hi all...

    First, this is exactly what I've been looking for!  I hope development continues!

    Here's my situation:  I work remotely with an office doing architectural drawings.  I have set up an FTP server to transfer the drawings back and forth.  When I use two-way sync, the latest files are copied to the server fine, but the next time I run the profile, the same files are copied back due to their new modified date.  I've tried using the .syncrules sample, but it only seems to sync once, no matter of the dates or file sizes.

    I would greatly appreciate a few regular expression examples from those that know better than I do.  How do I sync files that have different sizes, but ignore the modification dates if they have the same size?

    Also, is it possible at all to keep the original file date/time when transferring a file like this?  If so, maybe that should be an option in an upcoming release.

    When I have a better understanding of the syncrules, I'd be happy to help out by donating and updating the documentation.


    • Jan Kopcsek

      Jan Kopcsek - 2006-06-11

      Because many ftp-servers can not set the modification date of files and because of the fact that ascii file transfer results in different file sizes it is currently only possible to use Publish/Update when working with FTP servers. Publish/Update remembers how the files originally looked when it uploaded them to the server and can use this information to find changes.

      Using the advanced rules allowes you to change the compare behavior. In case it is enough for you to check for different file sizes you can try to remove the date compare line from the sample rule file. I don't guarantee for anything as those rules where originally some experiment for myself so they are not that rock stable. But i still use them myself so they do work ;).

      Just remove
      DEFINE SYNC "date != date"
      from the syncrules and use the two-way-sync profile. If that works... well... :D yay. Finally some extraordinary use of the advanced rules ;)

      If not i may have a look at it myself.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks