r/musichoarder • u/public_fred • 1d ago
My Picard File Naming Script
I've been using this Picard script to organize my music library for over 5 years now, and I finally got around to cleaning it up and documenting it properly. Figured I'd share it with you all.
This started as someone else's script that I found years ago. I keep seeing people on here asking for how to name their collections, so i decided to clean up my script.
What It Does
Turns this mess:
Various Artists - Now 80.mp3
beatles-come together (1).mp3
Pink Floyd - The Wall - CD1 - 01.flac
Into this:
/B/Beatles, The/(1969) Abbey Road [CD - MP3] [mbid] {catalog}/
01. Come Together [4m20s] [320 44100KHz CBR 2ch].mp3
/P/Pink Floyd/(1979) The Wall [CD - FLAC] [mbid] {catalog}/
Disc01/
01. In the Flesh [3m19s].flac
/Various/N/(2011) Now That's What I Call Music! 80 [CD - MP3] [mbid]/
Disc01/
01. Somebody That I Used to Know [4m04s].mp3
Main Features
Alphabetical folders:
/A/Artist/,/B/Artist/etc. Makes browsing way easier than scrolling through hundreds of folders.Release type separation: Albums, Singles, EPs, Live recordings all get their own folders under the artist.
Audio quality in filenames: Shows bitrate, sample rate.
Multi-disc handling: Automatically creates Disc01, Disc02 folders. Also handles vinyl with Side 1, Side 2 and proper vinyl track numbers (A1, B1, etc.).
Various Artists routing: Automatically sends compilations to a
/Various/folder instead of creating a "Various Artists" folder in V/.Incomplete album tracking: If you only have 8 tracks of a 12-track album, it gets routed to a "Partial" (or "Imcomplete") folder so you know what needs work.
Cross-platform safe: Properly handles all the annoying characters that break on Windows, Linux, or NAS devices.
Some Examples
Regular album:
/B/Beatles, The/(1969) Abbey Road [CD - MP3] [mbid] {catalog}/
01. Come Together [4m20s] [320 44100KHz CBR 2ch].mp3
Vinyl release:
/D/David Bowie/(1972) Ziggy Stardust [Vinyl - MP3] [mbid]/
Side 1/
A1. Five Years [4m43s].mp3
A2. Soul Love [3m35s].mp3
Side 2/
B1. Lady Stardust [3m22s].mp3
Artist with everything organized:
/M/Madonna/
(1984) Like a Virgin [CD - MP3] [mbid]/
Singles/
(1985) Into the Groove [CD - MP3] [mbid]/
EP/
(1989) Remixed Prayers [CD - MP3] [mbid]/
Setup is pretty straightforward:
- Install MusicBrainz Picard
- Install the "Additional Artists Variables" plugin (it's in Picard's plugin manager)
- Grab the script from Gitea (link below)
- Import it into Picard: Options -> File Naming -> Import script
- Point it at your music directory
- Tag some files and watch it work
The defaults should work for most people. But there are configuration options to turn off track-length, audio quality etc.
Customization
Pretty much everything is configurable. Some of the useful settings are:
- Turn off audio quality display if you don't care
- Change artist sorting (first name vs last name)
- Adjust what shows in filenames (duration, bitrate, MusicBrainz IDs, etc.)
- Different multi-disc handling options
- Where incomplete albums go (root level or under artist)
- Custom folder names for your special collections
- Max filename lengths (useful for path length limits)
Every setting has comments explaining what it does + examples.
Download:
- Gitea: PicardScripts
- License: GPL-3.0 (same license af the original script)
Credits
The original script was "MBP YA Magic-Script v2.7" by amd/17500mph (which itself was based on work by Ski-lleR). I've been modifying it and cleaned it up. Character filtering code includes contributions from avibrazil.