PDA

View Full Version : How to make SC keep out of some folders?



ofey
2008-06-26, 01:09
Dear community,

I'm searching for a possibility to control the SqueezeCenter music library scan to prevent it scanning the files in a few directories.

The background is that I want to join my music library with that of my brother, but some albums are contained in both libraries. The copy of my brother's music library should also serve as a desaster recovery backup.

Possible solutions would be:
- erase all duplicates (not an option due to the backup requirement)
- move all duplicates to a different directory structure not scanned by SC (lot of work and updating the copy requires all the work to be redone)
- set up a shadow directory structure with symlinks to the non-duplicate albums
- ?? something I may have missed ??

The ideal way for me would be to have a "blacklist" of subdirectories in the music folder that should be ignored when scanning the library, or a file with a specific name (e.gl ".keepout") to prevent SC to scan the folder.

Any idea would help.

TIA
ofey

mherger
2008-06-26, 01:26
> - ?? something I may have missed ??

There's an undocumented pref without UI - thus almost forgotton by most of
us...

if ((my $ignore = $prefs->get('ignoreDirRE') || '') ne '') {
return 0 if $item =~ /$ignore/;
}

You can define a regular expression which recognizes the folders you don't
want to scan. If you eg. add the following to server.prefs:

ignoreDirRE: '(?:backup|brothersmusic|badstuff)'

Then folders with the above words in the name will be ignored.

Michael

GlenL
2008-06-26, 02:13
Could you change the security settings/access lists on the specific album folders/directories so the account you run SqueezeCenter under is denied access to them ?

Not sure how SqueezeCenter rescan would react to being denied access to a specific subfolder, I assume it would just bypass it and carry on to the next folder/directory.

Worth a try.

JJZolx
2008-06-26, 02:52
The background is that I want to join my music library with that of my brother, but some albums are contained in both libraries. The copy of my brother's music library should also serve as a desaster recovery backup.

If only some albums are common to both libraries then it's not much of a backup.



Possible solutions would be:
- erase all duplicates (not an option due to the backup requirement)

Hard disk storage is cheap these days. Clean up the library and do regular full backups.

peter
2008-06-26, 04:13
On Thu, 26 Jun 2008 01:09:14 -0700, "ofey"
<ofey.3blrqn1214467801 (AT) no-mx (DOT) forums.slimdevices.com> said:
>
> The background is that I want to join my music library with that of my
> brother, but some albums are contained in both libraries. The copy of
> my brother's music library should also serve as a desaster recovery
> backup.

Uh oh, sounds illegal to me ;)

> or a file with a specific name (e.gl ".keepout") to prevent SC to scan
> the folder.

I'd like this option myself. Could also be handy if you want to keep
albums in different formats (mp3/flac) and allow SC to access only one.

Regards,
Peter