• Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login
    1. Strawberry Music Player Forums
    2. Sharky-PI
    • Profile
    • Following 0
    • Followers 0
    • Topics 10
    • Posts 50
    • Best 4
    • Controversial 0
    • Groups 0

    Sharky-PI

    @Sharky-PI

    8
    Reputation
    9
    Profile views
    50
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    Sharky-PI Unfollow Follow

    Best posts made by Sharky-PI

    • Multi genre support: implement semicolon split for Genre grouping in Collection

      This is as much of a discussion than a specific request.

      Previously requested here, (separate with ; ), here (for Subsonic, also separates with ; ), and here (general discussion).

      Foobar & some others support using ; to separate within field.

      OneTagger supports it but uses subgenres - I'm not fully sure how, though one option is by using a custom separate field; more info here.

      Beets has canonical nested genres which is pretty cool.

      Already in Strawberry if you tag a track with multiple genres split by ; e.g. "Microhouse;ClownPenis", that track will appear in a search for genre:microhouse and also genre:clownpenis, so that's great already. Similarly smart playlists work for "genre contains" any of multiple semicolon-separated terms.

      A downside is that if you group your collection by genre, the full term is shown, not both separate terms, which will cause the genres grouping to become nightmarishly messy.

      fd1ad5b6-ba92-413a-bf33-afe7ccda0968-image.png

      So I think feature request 1 is to allow Collection views which contain Genre to split tracks by semicolon and display the same track under both (or more) genre dropdowns.

      Keen for your thoughts. Cheers!

      posted in Feature Suggestions genre tagging collection
      Sharky-PIS
      Sharky-PI
    • Search term containing hyphen/dash in playlist doesn't return results despite them being present
      1. Find an album name with a hyphen/dash in it, e.g. "Enter The Wu-Tang (36 Chambers)"
      2. Make 2 new playlists with that album in it.
      3. From playlist 1, copy that name exactly (I love that you can hit F2 to make editable)
      4. In playlist 2, paste that name in the search bar. Nothing is returned until you delete the hyphen/dash.
      posted in Technical Help
      Sharky-PIS
      Sharky-PI
    • RE: Syncing the playlists to disk

      Strawberry Playlist Sync Tool

      Sync your Strawberry Music Player playlists to disk M3U files with duplicate detection, automatic backups, and smart conflict resolution.

      Features

      • Duplicate Detection: Find and remove duplicate tracks within playlists
        • Exact duplicates (same file added multiple times)
        • Optional fuzzy matching (same title/artist, different files)
      • Playlist Sync: Export database playlists to M3U files
        • Creates timestamped backups before overwriting
        • Shows what's added/removed before syncing
        • Add-only mode to preserve disk entries
        • Recursive subdirectory scanning
        • Multiple playlist directory support
      • Backup Rotation: Automatically clean up old backup files
        • Keep N backups per playlist (default: 3)
        • Delete backups older than N days (default: 60)
        • Count takes priority (always keeps minimum backups)
      • Never-Sync List: Skip utility playlists you don't want exported
        • Managed via neversync.txt in your playlist folder
        • Interactive prompts to add playlists during review

      Requirements

      • Python 3.6+ (standard library only, no pip installs needed)
      • Linux, macOS, or Windows

      Installation

      1. Save the script to your preferred location, e.g.:
        ~/.local/share/strawberry/strawberry/strawberry-playlist-sync.py
      2. Make it executable (Linux/macOS):
        chmod +x strawberry-playlist-sync.py
      3. Optionally create a desktop shortcut (see below).

      Usage

      Interactive Mode

      ./strawberry-playlist-sync.py
      Presents a menu to choose between duplicate checking, syncing, and backup cleanup.

      Command-Line Mode

      Dry run (preview changes without writing):
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists --dry-run

      Dry run with full track details:
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists --dry-run -v

      Sync playlists to disk:
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists

      Sync including subdirectories:
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists -r

      Check for duplicates:
      ./strawberry-playlist-sync.py -d

      Include fuzzy duplicates (same song, different files):
      ./strawberry-playlist-sync.py -d --fuzzy

      Clean up old backups:
      ./strawberry-playlist-sync.py -c -n 5 -a 30
      (Keep 5 backups, delete those older than 30 days)

      Run all operations:
      ./strawberry-playlist-sync.py -d -s -c -p ~/Music/playlists

      Automated mode (no prompts):
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists -y

      Multiple Directories

      ./strawberry-playlist-sync.py -s -p ~/Music/playlists -p /media/usb/playlists

      Command-Line Options
      ┌─────────────────────────┬─────────────────────────────────────────────────┐
      │ Option │ Description │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -d, --check-duplicates │ Find and remove duplicate tracks │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ --fuzzy │ Include fuzzy duplicates in check │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -s, --sync │ Sync database playlists to disk │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -c, --cleanup-backups │ Clean up old backup files │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -p, --playlist-dir PATH │ Playlist folder (can be used multiple times) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -r, --recursive │ Scan subdirectories for M3U files │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ --add-only │ Only add tracks, preserve existing disk entries │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ --db-path PATH │ Path to strawberry.db (auto-detects if not set) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -n, --keep-count N │ Backups to keep per playlist (default: 3) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -a, --max-age DAYS │ Max backup age in days (default: 60) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ --dry-run │ Preview changes without writing │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -v, --verbose │ Show full track details (with --dry-run) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -y, --yes │ Skip confirmation prompts │
      └─────────────────────────┴─────────────────────────────────────────────────┘
      Never-Sync List

      To exclude playlists from syncing (e.g., utility playlists for finding missing metadata):

      1. During interactive review, when you skip a playlist, you'll be asked if you want to add it to the never-sync list.
      2. Or manually edit neversync.txt in your playlist folder:

      Playlists listed here will be skipped during sync operations.

      NoComposerSP
      BitrateLessThan129SP
      UnratedSP

      Desktop Shortcut (Linux)

      Create a shell script on your desktop:

      #!/bin/bash

      Strawberry Playlist Sync

      ~/.local/share/strawberry/strawberry/strawberry-playlist-sync.py -s -p ~/Music/playlists -r

      Save as strawberry-playlist-sync.sh and make executable with chmod +x.

      Database Locations

      The script auto-detects Strawberry's database in these locations:

      • Linux: ~/.local/share/strawberry/strawberry/strawberry.db
      • macOS: ~/Library/Application Support/Strawberry/strawberry/strawberry.db
      • Windows: ~/AppData/Local/strawberry/strawberry/strawberry.db

      Use --db-path to specify a custom location.

      Notes

      • Safe to run with Strawberry open: The script only reads from the database (except for duplicate removal), so syncing while Strawberry is running is fine. For
        duplicate removal, close Strawberry first.
      • Backups: Before overwriting any M3U file, a timestamped backup is created in a backups/ subfolder.
      • M3U Format: Uses extended M3U with #EXTINF:seconds,Artist - Title lines.
      • Path Handling: Automatically converts database file:// URLs to filesystem paths and handles URL-encoded characters.

      License

      Public domain / CC0. Use however you like.

      Created by me and Claude Code tonight.

      posted in Feature Suggestions
      Sharky-PIS
      Sharky-PI
    • RE: Multi genre support: implement semicolon split for Genre grouping in Collection

      @jonas any thoughts about this, chap?

      posted in Feature Suggestions
      Sharky-PIS
      Sharky-PI

    Latest posts made by Sharky-PI

    • RE: Syncing the playlists to disk

      Strawberry Playlist Sync Tool

      Sync your Strawberry Music Player playlists to disk M3U files with duplicate detection, automatic backups, and smart conflict resolution.

      Features

      • Duplicate Detection: Find and remove duplicate tracks within playlists
        • Exact duplicates (same file added multiple times)
        • Optional fuzzy matching (same title/artist, different files)
      • Playlist Sync: Export database playlists to M3U files
        • Creates timestamped backups before overwriting
        • Shows what's added/removed before syncing
        • Add-only mode to preserve disk entries
        • Recursive subdirectory scanning
        • Multiple playlist directory support
      • Backup Rotation: Automatically clean up old backup files
        • Keep N backups per playlist (default: 3)
        • Delete backups older than N days (default: 60)
        • Count takes priority (always keeps minimum backups)
      • Never-Sync List: Skip utility playlists you don't want exported
        • Managed via neversync.txt in your playlist folder
        • Interactive prompts to add playlists during review

      Requirements

      • Python 3.6+ (standard library only, no pip installs needed)
      • Linux, macOS, or Windows

      Installation

      1. Save the script to your preferred location, e.g.:
        ~/.local/share/strawberry/strawberry/strawberry-playlist-sync.py
      2. Make it executable (Linux/macOS):
        chmod +x strawberry-playlist-sync.py
      3. Optionally create a desktop shortcut (see below).

      Usage

      Interactive Mode

      ./strawberry-playlist-sync.py
      Presents a menu to choose between duplicate checking, syncing, and backup cleanup.

      Command-Line Mode

      Dry run (preview changes without writing):
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists --dry-run

      Dry run with full track details:
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists --dry-run -v

      Sync playlists to disk:
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists

      Sync including subdirectories:
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists -r

      Check for duplicates:
      ./strawberry-playlist-sync.py -d

      Include fuzzy duplicates (same song, different files):
      ./strawberry-playlist-sync.py -d --fuzzy

      Clean up old backups:
      ./strawberry-playlist-sync.py -c -n 5 -a 30
      (Keep 5 backups, delete those older than 30 days)

      Run all operations:
      ./strawberry-playlist-sync.py -d -s -c -p ~/Music/playlists

      Automated mode (no prompts):
      ./strawberry-playlist-sync.py -s -p ~/Music/playlists -y

      Multiple Directories

      ./strawberry-playlist-sync.py -s -p ~/Music/playlists -p /media/usb/playlists

      Command-Line Options
      ┌─────────────────────────┬─────────────────────────────────────────────────┐
      │ Option │ Description │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -d, --check-duplicates │ Find and remove duplicate tracks │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ --fuzzy │ Include fuzzy duplicates in check │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -s, --sync │ Sync database playlists to disk │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -c, --cleanup-backups │ Clean up old backup files │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -p, --playlist-dir PATH │ Playlist folder (can be used multiple times) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -r, --recursive │ Scan subdirectories for M3U files │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ --add-only │ Only add tracks, preserve existing disk entries │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ --db-path PATH │ Path to strawberry.db (auto-detects if not set) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -n, --keep-count N │ Backups to keep per playlist (default: 3) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -a, --max-age DAYS │ Max backup age in days (default: 60) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ --dry-run │ Preview changes without writing │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -v, --verbose │ Show full track details (with --dry-run) │
      ├─────────────────────────┼─────────────────────────────────────────────────┤
      │ -y, --yes │ Skip confirmation prompts │
      └─────────────────────────┴─────────────────────────────────────────────────┘
      Never-Sync List

      To exclude playlists from syncing (e.g., utility playlists for finding missing metadata):

      1. During interactive review, when you skip a playlist, you'll be asked if you want to add it to the never-sync list.
      2. Or manually edit neversync.txt in your playlist folder:

      Playlists listed here will be skipped during sync operations.

      NoComposerSP
      BitrateLessThan129SP
      UnratedSP

      Desktop Shortcut (Linux)

      Create a shell script on your desktop:

      #!/bin/bash

      Strawberry Playlist Sync

      ~/.local/share/strawberry/strawberry/strawberry-playlist-sync.py -s -p ~/Music/playlists -r

      Save as strawberry-playlist-sync.sh and make executable with chmod +x.

      Database Locations

      The script auto-detects Strawberry's database in these locations:

      • Linux: ~/.local/share/strawberry/strawberry/strawberry.db
      • macOS: ~/Library/Application Support/Strawberry/strawberry/strawberry.db
      • Windows: ~/AppData/Local/strawberry/strawberry/strawberry.db

      Use --db-path to specify a custom location.

      Notes

      • Safe to run with Strawberry open: The script only reads from the database (except for duplicate removal), so syncing while Strawberry is running is fine. For
        duplicate removal, close Strawberry first.
      • Backups: Before overwriting any M3U file, a timestamped backup is created in a backups/ subfolder.
      • M3U Format: Uses extended M3U with #EXTINF:seconds,Artist - Title lines.
      • Path Handling: Automatically converts database file:// URLs to filesystem paths and handles URL-encoded characters.

      License

      Public domain / CC0. Use however you like.

      Created by me and Claude Code tonight.

      posted in Feature Suggestions
      Sharky-PIS
      Sharky-PI
    • RE: Syncing the playlists to disk

      @jonas any possibility to add this feature - automatically save some/all playlists to disk on edit?

      Paired with duplicate detection, this would mean users aren't solely relying on the strawberry database to preserve the sanctity of their playlists.

      Thanks!

      posted in Feature Suggestions
      Sharky-PIS
      Sharky-PI
    • Prevent duplicate playlist additions

      Hi @jonas , hope you're well.

      Any scope to add a settings option to prevent addition of (what would be) duplicate items to playlists?

      Cheers!

      posted in Feature Suggestions
      Sharky-PIS
      Sharky-PI
    • RE: Solitary date-style composer tag inexplicably under "M" heading

      Another potentially useful datum:

      a0a8971f-b85b-401c-8888-552e8227d7c8-image.png

      All House genre tracks dumped into a playlist, sorted by composer (my 'date added' column): works EXCEPT 2023.01.23, and 2024.10.30, both sort out of order. 2023.01.23 weirdly don't sort next to each other.

      e8c7d396-4d10-42d0-bff5-0d5060ff3107-image.png

      unicode characters are normal for the correctly sorted entries,

      bea93f1b-ab1a-4457-8091-6e73ec6bc161-image.png

      but also the incorrectly sorted ones, so it looks like it's not a characters issue (I've typed all of these manually so inserting unicode seemed unlikely but just in case)

      posted in Technical Help
      Sharky-PIS
      Sharky-PI
    • RE: Solitary date-style composer tag inexplicably under "M" heading

      @jonas potentially useful data point:

      62e63ac3-a576-4866-bf0c-d99d480a8078-image.png

      µ-Ziq, conceptually but not actually beginning with M, is filed under M, but the Georgian deep house artist below is filed under their first character.

      So weird it's fine for you but weird for me though...!

      (edit, this is grouped by Artist/Album, but is potentially useful info)

      posted in Technical Help
      Sharky-PIS
      Sharky-PI
    • RE: Solitary date-style composer tag inexplicably under "M" heading

      Just updated to 1.2.14, no change

      posted in Technical Help
      Sharky-PIS
      Sharky-PI
    • RE: Solitary date-style composer tag inexplicably under "M" heading

      rebooted:

      locale
      LANG=en_GB.UTF-8
      LANGUAGE=en_GB:en
      LC_CTYPE="en_GB.UTF-8"
      LC_NUMERIC=en_GB.UTF-8
      LC_TIME=en_GB.UTF-8
      LC_COLLATE="en_GB.UTF-8"
      LC_MONETARY=en_GB.UTF-8
      LC_MESSAGES="en_GB.UTF-8"
      LC_PAPER=en_GB.UTF-8
      LC_NAME=en_GB.UTF-8
      LC_ADDRESS=en_GB.UTF-8
      LC_TELEPHONE=en_GB.UTF-8
      LC_MEASUREMENT=en_GB.UTF-8
      LC_IDENTIFICATION=en_GB.UTF-8
      LC_ALL=

      No change to those files. The mystery deepens. This is so weird...

      posted in Technical Help
      Sharky-PIS
      Sharky-PI
    • RE: Solitary date-style composer tag inexplicably under "M" heading

      @jonas oh weird.

      Ubuntu 25.04, language English UK, formats USA but I'll change that to UK. Currently:

      locale
      LANG=en_GB.UTF-8
      LANGUAGE=en_GB:en
      LC_CTYPE="en_GB.UTF-8"
      LC_NUMERIC=en_US.UTF-8
      LC_TIME=en_US.UTF-8
      LC_COLLATE="en_GB.UTF-8"
      LC_MONETARY=en_US.UTF-8
      LC_MESSAGES="en_GB.UTF-8"
      LC_PAPER=en_US.UTF-8
      LC_NAME=en_US.UTF-8
      LC_ADDRESS=en_US.UTF-8
      LC_TELEPHONE=en_US.UTF-8
      LC_MEASUREMENT=en_US.UTF-8
      LC_IDENTIFICATION=en_US.UTF-8
      LC_ALL=

      I'll reboot for UK and see if it changes anything.

      posted in Technical Help
      Sharky-PIS
      Sharky-PI
    • RE: Solitary date-style composer tag inexplicably under "M" heading

      Some diagnosis attempts from Claude, unsuccessful:

      All other dates work correctly, including:
      2024.10.31 ✓
      2024.10.20 ✓
      2024.10.10 ✓
      2025.07.30 ✓
      2025.09.30 ✓
      All other October 2024 dates ✓

      What This ISN'T:

      ❌ Integer division (30 // 10 = 3) - would affect 2024.10.31 too
      ❌ Simple format swap (YYYY.DD.MM) - would affect 2024.10.31, 2024.03.10
      ❌ All .30 dates - only 2024.10.30 breaks
      ❌ All month=10 dates - other October 2024 dates work
      ❌ Hash collision or mathematical artifact
      ❌ Hex/binary representation quirk

      Critical Finding
      The sort key starts with 'M'
      The grouping header comes from the first character of the sort key. For 2024.10.30 to appear under 'M', its sort key must start with 'M' (not '2' or '0').
      Possible Explanations:

      Date parsing creates month name string - Parser detects date → converts to "March ..." (month 3) → sort key = "March..." → first char = 'M'
      Specific string replacement - Code replaces "2024.10.30" with month name starting with 'M' (March, May, etc.)
      Locale-specific format string - Date formatter outputs "M..." format for this specific date only
      Sort tag generation bug - Composer field has special date handling that generates month-based sort keys

      Theories That Fit
      Month 3 (March) Connection:

      30 - 27 = 3 → March
      Some wrapping/modulo creating month 3 from day 30
      But why doesn't 31 also break?

      Most Likely:
      Specific pattern/regex matching *.10.30 or 2024.10.30 that triggers date-to-month-name conversion, outputting something like "March 2024" or "Mar..." as the sort key.
      What We Can't Check (Need Codebase Access)

      SortText generation for composer field - does it attempt date parsing?
      Date-to-string conversion - any code converting dates to month names for sorting?
      Sort key logic - what generates the sortable string from composer tag?
      Hardcoded patterns - search for "10.30", "2024.10.30", or month name generation
      Article/prefix stripping - any "A"/"The" logic that might affect numbers?
      Sort tags feature (v1.2.12) - recent addition, potential new bug

      Files to Examine

      src/collection/collectionmodel.cpp - sorting/grouping/header logic
      src/core/song.cpp - SortText generation for composer field
      Date parsing utilities
      Any locale/format conversion for sorting
      Recent commits related to sort tags

      posted in Technical Help
      Sharky-PIS
      Sharky-PI
    • RE: Solitary date-style composer tag inexplicably under "M" heading

      @jonas https://drive.google.com/drive/folders/1W4HT_7AmekeCfh6rdav01jfd3Bhx_Ij0?usp=sharing copied them here but I'm >99% sure it's not the files: I personally tagged them with that specific composer string and only that string seems to cause them to be filed under M.

      I just did the same for a random song which wasn't tagged with composed, and it then becomes populated under M like the others:
      2c1f9510-b45f-415b-a672-08b84a395b86-image.png

      posted in Technical Help
      Sharky-PIS
      Sharky-PI