Home of the Squeezebox™ & Transporter® network music players.
Results 1 to 5 of 5
  1. #1
    Senior Member
    Join Date
    Feb 2009
    Location
    Cambridge, UK
    Posts
    401

    tell LMS to ignore some dirs whilst scanning

    quickie question, pleaseů

    Is there any quick way to get LMS to ignore directories (recursively, i.e. a dir hierarchy) whilst scanning, with some sort of sentinel file? A little like Android's ".nomedia" file, for example?

    I could go in and change filename extensions, but that doesn't scale well, and will result in the "changed" files being backed up again (unnecessarily).

    thanks very much.

  2. #2
    Senior Member
    Join Date
    May 2008
    Location
    United States
    Posts
    11,516
    Quote Originally Posted by cdmackay View Post
    quickie question, please…

    Is there any quick way to get LMS to ignore directories (recursively, i.e. a dir hierarchy) whilst scanning, with some sort of sentinel file? A little like Android's ".nomedia" file, for example?

    I could go in and change filename extensions, but that doesn't scale well, and will result in the "changed" files being backed up again (unnecessarily).

    thanks very much.
    I can't recall where I saw this, but I have a very vague recollection that if you name the directory you don't want scanned to start with a period, that may do what you want. For example,

    c:\othermusic
    would be named instead
    c:\.othermusic

    I could be entirely misremembering, but you can test easily enough.

    EDIT: Found this. It may be that the "." only works with linux.
    https://forums.slimdevices.com/showt...rs-from-a-scan
    Last edited by garym; 2019-07-21 at 17:13.
    Home: VBA 4TB (2.5)>LMS 7.9.2>Transporter, Touch, Boom, Radio (all ethernet)
    Cottage: VBA 3TB (2.4)>LMS 7.9.1>Touch>Benchmark DAC I, Boom, Radio w/Battery (ethernet, Radio WIFI)
    Office: Win10(64)>LMS 7.9.2>Squeezelite
    The Wild (no internet): PiCorePlayer 4.0 on rPi 3B+, hifiberry Dac+Pro, 4TB USB (LMS & Squeezelite)
    Controllers: iPhone6 & iPadAir2 (iPeng), CONTROLLER, or SqueezePlay 7.8 on Win10(64) laptop
    Files: ripping: dbpa > FLAC; post-rip: mp3tag, PerfectTunes; Streaming: Spotify

  3. #3
    Can you just change the directory permissions so LMS cannot see or read the files?
    owner of the stuff at https://tuxreborn.netlify.com/
    (which used to reside at www.tux.org/~peterw/)
    Note: The best way to reach me is email or PM, as I don't spend much time on the forums.
    Free plugins: AllQuiet Auto Dim/AutoDisplay BlankSaver ContextMenu DenonSerial
    FuzzyTime KidsPlay KitchenTimer PlayLog PowerCenter/BottleRocket SaverSwitcher
    SettingsManager SleepFade StatusFirst SyncOptions VolumeLock

  4. #4
    Senior Member
    Join Date
    Aug 2012
    Location
    Austria
    Posts
    923
    edit your server.prefs while LMS is stopped:

    Code:
    ignoreDirRE: ''
    ignoreInAudioScan: []
    ignoreInImageScan:
    - /data/music
    ignoreInVideoScan:
    - /data/music
    first one takes a regular expression, others a list of file paths
    Various SW: Web Interface | Playlist Editor / Generator | Music Classification | Similar Music | Announce | EventTrigger | LMSlib2go | ...
    Various HowTos: build a self-contained LMS | Bluetooth/ALSA | Control LMS with any device | ...

  5. #5
    Senior Member
    Join Date
    Feb 2009
    Location
    Cambridge, UK
    Posts
    401
    Thanks very much indeed, all, for the suggestions; clearly I didn't search well enough, sorry.

    Quote Originally Posted by garym View Post
    I can't recall where I saw this, but I have a very vague recollection that if you name the directory you don't want scanned to start with a period, that may do what you want. For example,

    I could be entirely misremembering, but you can test easily enough.

    EDIT: Found this. It may be that the "." only works with linux.
    https://forums.slimdevices.com/showt...rs-from-a-scan
    The '.' hidden dir is an idea, since I am running LMS on Linux, but it would also hide the dirs from a regular ls (not ls -a) and that might confuse me later. But your linked post also contained exactly what I wanted, as did Roland0's, below.


    Quote Originally Posted by peterw View Post
    Can you just change the directory permissions so LMS cannot see or read the files?
    That's a nice idea, but I bet it would create Error noise in scanner.log, which I already search to find badly tagged items, so that would be a false positive I'd have to ignore.


    Quote Originally Posted by Roland0 View Post
    edit your server.prefs while LMS is stopped:

    Code:
    ignoreDirRE: ''
    ignoreInAudioScan: []
    ignoreInImageScan:
    - /data/music
    ignoreInVideoScan:
    - /data/music
    first one takes a regular expression, others a list of file paths
    Now that looks perfect, thanks! I can set the RE to ".*\.hidden", then append that to the dirs I want to hide.

    thanks again, all, much appreciated.
    Last edited by cdmackay; 2019-07-22 at 09:24. Reason: corrected RE

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •