I've been using the synchronize function quite often of late, comparing directories that have been checked out of a Subversion repository. There are a number of subdirectories and other files that follow a well defined pattern that I'd like to exclude from the comparison.
Using a filter I've been able to exclude most of them, but the .svn subdirectories always seem to work their way back into the comparison no matter what I do with the filter. I've tried countless variations. Sometimes they work for a while, then I make a small change that shouldn't affect the .svn clause, and there come the .svn directories back into the comparison.
The closest I've come to what I want to accomplish is with using regex in the filter. Here's my latest attempt:
<?xml version="1.0" encoding="UTF-8"?>
<filter desc="" name="xxx source">
<clause match="no" regexp="yes" type="name">.+\.(o|d|a|tar)$</clause>
<clause link="and" match="no" regexp="yes" type="name">.+_proto.h$</clause>
<clause link="and" match="no" regexp="yes" type="name">.+~$</clause>
<clause link="and" match="no" regexp="yes" type="path">.*(\\?|/?)(1394|dalsa|bin|debug|\.svn)(\\|/).*</clause>
The last clause is the big one. It's supposed to exclude from comparison any path that has 1394, dalsa, bin, debug, or .svn as a directory element of the path. I used "(\?|/?)" because I sometimes do syncs via FTP with a unix box and I wasn't sure how it would report directory separators in the path. This should catch either slash character.
Any suggestions on how to make this work would be greatly appreciated.