Greetings all,
I wish to exclude all mp3 files from a certain folder location (but not any other folder location), and the exclude string I've tried is as follows:
\Users\John\AppData\Local\GeometryDash\*.mp3
but the mp3 files don't disappear from the folder pair display, and the mp3 files still get copied.
(Edit: from what I've read in the thread "[UserManual] Filter wildcards are greedy" 26/11/2019 the above exclude string should work, but it doesn't. Puzzled I am...)
(The source folder is on another computer on the network, \\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\ is the full path to the folder containing the unwanted mp3 files.)
Using this as a filter: *.mp3 does work, and when that string is inserted in the filter and the filter is saved, the mp3 files disappear from the folder pair display, but I assume that filter excludes files with a mp3 extension from anywhere in the other folders being copied, and I don't want that to happen.
I suppose I've missed something obvious, but I've no idea what, so can anyone enlighten me?
Thanks in advance,
Roger V.
A puzzle with the "exclude" filter
- Posts: 12
- Joined: 5 Dec 2017
- Site Admin
- Posts: 7212
- Joined: 9 Dec 2007
As always, filter phrases in FFS are relative to the base folder pairs. This is written in the filter dialog directly, but also in the manual (which is designed to be only *optional* for using FFS).
However, I'm just realising the best solution would be for FFS to just correct those absolute paths into relative ones, since it's always an error, and FFS (in most cases) already has the required info available. => To Do
However, I'm just realising the best solution would be for FFS to just correct those absolute paths into relative ones, since it's always an error, and FFS (in most cases) already has the required info available. => To Do
- Posts: 12
- Joined: 5 Dec 2017
Thanks :-) But I'm still confused...
So if I want to avoid copying all the files with the extension .mp3 in this source folder:
\\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\
what exclude filter phrase should I actually use?
(I'll probably kick myself when I find out how easy it is... :-) )
So if I want to avoid copying all the files with the extension .mp3 in this source folder:
\\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\
what exclude filter phrase should I actually use?
(I'll probably kick myself when I find out how easy it is... :-) )
- Posts: 292
- Joined: 13 Apr 2017
Assuming you have only one folder pair:
- remove anything but * from your include filter
- your exclude filter may contain something like this:
\System Volume Information\
\$Recycle.Bin\
\RECYCLER\
\RECYCLED\
*\desktop.ini
*\thumbs.db
In case, remove anything related to mp3 files.
- add a folder pair with the same left and right folders
- in the local filter of the first folder pair put/add *.mp3 in the exclude filter
- in the local filter of the second folder pair put \*\*.mp3 alone in the include filter
Done.
Tricky but works.
Explanation:
Excluding *.mp3 really exclude them totally.
Including them with this syntax \*\*.mp3 include them only from sub-folders.
- remove anything but * from your include filter
- your exclude filter may contain something like this:
\System Volume Information\
\$Recycle.Bin\
\RECYCLER\
\RECYCLED\
*\desktop.ini
*\thumbs.db
In case, remove anything related to mp3 files.
- add a folder pair with the same left and right folders
- in the local filter of the first folder pair put/add *.mp3 in the exclude filter
- in the local filter of the second folder pair put \*\*.mp3 alone in the include filter
Done.
Tricky but works.
Explanation:
Excluding *.mp3 really exclude them totally.
Including them with this syntax \*\*.mp3 include them only from sub-folders.
- Posts: 12
- Joined: 5 Dec 2017
Hi Gianni,
Thanks for your suggestion. :-)
I'm still rather confused (even though I've been a thankful FreeFileSync user for a few years...)
By the way, in that particular sync configuration (or sync job, I guess), I have 24 folder pairs (3 users on 1 pc have their files synced with another pc on the home network) but it sails through it with no problems.
So, to avoid copying mp3 files from this folder (which is on the left of course) :
\\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\
to the target folder, which is C:\_SCH_Desktop1\John\Geometry Dash (a folder in a large HDD on the PC upon which I'm typing this post)...
I need to put the same folder on the right, (instead of the current folder which is presently on the right) while doing the following to the local filters of each of these two folders (and I'm quoting you here, to save typing):
- in the local filter of the first folder pair put/add *.mp3 in the exclude filter
- in the local filter of the second folder pair put \*\*.mp3 alone in the include filter
But if I "add a folder pair with the same left and right folders" , aren't I trying to copy the contents of a folder to itself?
As I said, I'm a little confused, and I've probably misunderstood what you're trying to suggest.
I'll just grab another coffee and try to ram this into my thick skull... :-)
Kind regards,
Roger V.
Thanks for your suggestion. :-)
I'm still rather confused (even though I've been a thankful FreeFileSync user for a few years...)
By the way, in that particular sync configuration (or sync job, I guess), I have 24 folder pairs (3 users on 1 pc have their files synced with another pc on the home network) but it sails through it with no problems.
So, to avoid copying mp3 files from this folder (which is on the left of course) :
\\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\
to the target folder, which is C:\_SCH_Desktop1\John\Geometry Dash (a folder in a large HDD on the PC upon which I'm typing this post)...
I need to put the same folder on the right, (instead of the current folder which is presently on the right) while doing the following to the local filters of each of these two folders (and I'm quoting you here, to save typing):
- in the local filter of the first folder pair put/add *.mp3 in the exclude filter
- in the local filter of the second folder pair put \*\*.mp3 alone in the include filter
But if I "add a folder pair with the same left and right folders" , aren't I trying to copy the contents of a folder to itself?
As I said, I'm a little confused, and I've probably misunderstood what you're trying to suggest.
I'll just grab another coffee and try to ram this into my thick skull... :-)
Kind regards,
Roger V.
- Posts: 12
- Joined: 5 Dec 2017
One last thought for this morning...
I've been reading the online manual for FFS, where it says this:
Example: Filter items of folder pair C:\Source, D:\Target
Filter description --------------------------------- Filter phrase
All *.tmp files located in SubFolder ----------- \SubFolder\*.tmp
Once I put that in the exclude filter and click OK to close that window, all .tmp files in folder "subfolder" should disappear from the preview screen, as far as I understand, and won't be actually copied.
So, for this folder,
\\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\
to avoid copying mp3 files, I put this filter phrase in the exclude filter (which I believe is relative to the base folder pair):
\Geometry Dash\*.mp3
and then I clicked OK to close the window, and I saved the configuration.
This should work, as it follows the pattern suggested in the manual. But it doesn't work. :-(
It doesn't cause the files to disappear from the preview screen, and as I run this sync job as I type, it copied the unwanted mp3 files to the target folder, as I suspected it would.
So, I'll leave this for the moment, and I welcome further comment if anyone's got the time or inclination. :-)
Kind regards,
Roger V.
I've been reading the online manual for FFS, where it says this:
Example: Filter items of folder pair C:\Source, D:\Target
Filter description --------------------------------- Filter phrase
All *.tmp files located in SubFolder ----------- \SubFolder\*.tmp
Once I put that in the exclude filter and click OK to close that window, all .tmp files in folder "subfolder" should disappear from the preview screen, as far as I understand, and won't be actually copied.
So, for this folder,
\\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\
to avoid copying mp3 files, I put this filter phrase in the exclude filter (which I believe is relative to the base folder pair):
\Geometry Dash\*.mp3
and then I clicked OK to close the window, and I saved the configuration.
This should work, as it follows the pattern suggested in the manual. But it doesn't work. :-(
It doesn't cause the files to disappear from the preview screen, and as I run this sync job as I type, it copied the unwanted mp3 files to the target folder, as I suspected it would.
So, I'll leave this for the moment, and I welcome further comment if anyone's got the time or inclination. :-)
Kind regards,
Roger V.
- Posts: 292
- Joined: 13 Apr 2017
First thing I should have asked is your exact folder pair and the type of synchronization (Two way, Mirror, etc.)
I try to guess:
Synchronization variant: Mirror
Left: \\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\
Right: C:\_SCH_Desktop1\John\GeometryDash\
>But if I "add a folder pair with the same left and right folders" ,
>aren't I trying to copy the contents of a folder to itself?
No, at most you are performing two times the same copy operation.
Try to follow my previous guide!
I try to guess:
Synchronization variant: Mirror
Left: \\SCH-DESKTOP1\Users\John\AppData\Local\GeometryDash\
Right: C:\_SCH_Desktop1\John\GeometryDash\
>But if I "add a folder pair with the same left and right folders" ,
>aren't I trying to copy the contents of a folder to itself?
No, at most you are performing two times the same copy operation.
Try to follow my previous guide!
- Posts: 12
- Joined: 5 Dec 2017
Thanks for you reply :-)
Actually, I'm using two way sync on this job.
But, that doesn't seem to mater, for when I tried your suggestion (once I understood what you were actually trying to get me to do....) it worked, so thanks again. :-)
I'm still curious as to why this following filter phrase doesn't work, though:
\Geometry Dash\*.mp3
because it seems to follow the suggestion from the manual, ie:
\SubFolder\*.tmp
But... never mind. :-)
Thanks again,
Kind regards,
Roger V.
Actually, I'm using two way sync on this job.
But, that doesn't seem to mater, for when I tried your suggestion (once I understood what you were actually trying to get me to do....) it worked, so thanks again. :-)
I'm still curious as to why this following filter phrase doesn't work, though:
\Geometry Dash\*.mp3
because it seems to follow the suggestion from the manual, ie:
\SubFolder\*.tmp
But... never mind. :-)
Thanks again,
Kind regards,
Roger V.
- Posts: 292
- Joined: 13 Apr 2017
FFS consider the left and right folders the "root", the starting point of any subsequent processing.
FFS don't consider anything back in the left and right paths.
Everything in the filters must be relative to this "root".
FFS don't consider anything back in the left and right paths.
Everything in the filters must be relative to this "root".
- Posts: 12
- Joined: 5 Dec 2017
Thanks for your help. :-)
Kind regards,
Roger V.
Kind regards,
Roger V.
- Site Admin
- Posts: 7212
- Joined: 9 Dec 2007
"Full path to relative path" detection and conversion has been added for the next FFS release: viewtopic.php?t=9225#p34808