exclude full filename: file.txt
- only in rootdir \file.txt
- only in subdir \subdir\file.txt
- overall, in root und subdir *\file.txt
that works as expectedly
filetyp only: *.txt
i expected:
- only in rootdir \*.txt doesn’t work ! doesn't sync *.txt in root AND subdir …
- only in subdir \*\*.txt ok
- overall, in root und subdir *\*.txt ok
Whats going wrong?
volker01
Filter Exclude *.txt only in basedir ...
- Posts: 102
- Joined: 14 Feb 2015
- Posts: 2524
- Joined: 22 Aug 2012
In the definition \*.txt, the * can also stand for *\*, which then makes it identical to your \*\*.txt in your next line and behaves accordingly.... i expected:
- only in rootdir \*.txt doesn’t work ! doesn't sync *.txt in root AND subdir …
...Whats going wrong?volker01, 05 Aug 2018, 12:23
There is no simple direct way to exclude files in a folder but not in subfolders thereof if the filter description includes a * .
You can follow the same approach as described in the include exclude filter section of the manual:
The "trick" is to use two left-right folder pairs instead of just one.
There are multiple ways of achieving what you want, but here's an example:
Pair 1 is the (source) rootdir and the (destination) rootdir
The local (to the 1st left-right pair) Include filter is * and the local Exclude filter is *.txt .
This will exclude all *.txt-files from the sync, also those in subfolders
Pair 2 is also the (source) rootdir and the (destination) rootdir
The local (to the 2nd left-right pair) Include filter is \*\*.txt and the local Exclude filter is empty.
This will include all *.txt-files in all subfolders, but not the one(s) in the rootdir.
- Posts: 102
- Joined: 14 Feb 2015
Thank you,
is ffs running twice when syncing two idendical folder pairs?
is ffs running twice when syncing two idendical folder pairs?
- Posts: 2524
- Joined: 22 Aug 2012
If you define a single FFS job having two (here identical) left-right folder pairs
(as per the above example), the sync is just a single instance of FFS.
If you would define it as two separate FFS jobs these would be two separate instances of FFS.
If you have overlap in your left-right pairs and would use a sync variant that uses directory locking, you would need to run these two FFS jobs consecutively.
(as per the above example), the sync is just a single instance of FFS.
If you would define it as two separate FFS jobs these would be two separate instances of FFS.
If you have overlap in your left-right pairs and would use a sync variant that uses directory locking, you would need to run these two FFS jobs consecutively.