Repository for neat file name string patterns and tagger script snippets

I just happened to look in here, as I’m fixing a bunch of tracks from an archive … and wanted to see something on why my script isn’t replacing the colons in the filenames with the UTF8 equal… ∢ because I’m getting / substitutes in just the filenames, not the pathnames. That’s working properly.

$noop(β˜… : ➑ ∢)
$set(_titleForFilename,$replace(%_titleForFilename%,:,∢))
$set(_albumForFilename,$replace(%_albumForFilename%,:,∢))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,:,∢))
$set(_artistForFilename,$replace(%_artistForFilename%,:,∢))
$set(_albumartistForFilename,$replace(%_albumartistForFilename%,:,∢))
$set(_artistsortForFilename,$replace(%_artistsortForFilename%,:,∢))
$set(_albumartistsortForFilename,$replace(%_albumartistsortForFilename%,:,∢))

I think it’s something in there, with the _titleForFilename except that you can see where it’s even working in the screenshot, and the timecode in the same filename [xx∢xx] is showing correctly.

It’s been several months since I looked at this thing.

Post a sample of what it’s doing and what you want with dates, order of segments, whatever and I’ll see what config options I have that might do it, or even at least make it work that the suggestion from @Billy_Yank…

The small red circles are where it’s doing it, and not doing it. The first instance of : is changed, as is the second, but the resulting filename is giving me / in place of the first one, and the second one is correct.

I think I need to change a variable name, or more like do the same thing on an additional something to do with the filename string.

Beware, my Picard build may have different looking things in the UI, it’s a specific build, but all the script functions work, with one exception. How it handles duplicate files. It’s talked about in one of my earlier posts)

The YA Magic Script is a lot more flexible when you’ve got Keyboard Maestro or such (Macro Generator) to match up with it. I’ve got the scripts accessible via an added menu on the menu bar so that I can refer to them by name / menu path

instead of playing voodoo with making contextual menus

Because the heck with that crap. It’s just totally maddening. Though I suppose during Covid Lockdown you’ll have an alternate way to deal with haircuts… you’ll just pull all your hair out trying to make that contextual crap work with scripts.

Hello again wonderfull people!

say I want to have 3 more scripts to organise m,y compilations just like this one:

I use this one for compilations "curated by, prepared by… (Buddah bar, cafe del mar etc…)

$set(albumartist,Various Artists)
$set(albumartistsort,Various Artists)
$set(musicbrainz_albumartistid,89ad4ac3-39f7-470e-963a-56509c546377)

1- One for Soundtracks: (Various artists + Soundtrack release type)

2- One for dj mix / live dj set ie: non-compilation, non album, Recorded live dj-set not part of an album types ???
NOT LIKE THIS:>>> https://musicbrainz.org/series/f4c40be4-3eb2-416b-83ea-af00119eb99b

3- One For what I call dj-compilations series which are mixed by a dj (Fabric, dj kicks): https://musicbrainz.org/release-group/1ce91abd-bf21-38e2-ab17-7fecb6c69337

I searched for the Soundtrack/dj-mix release types MBID but couldn’t find a list of MBID’s?

how would I go about finding this info?

Or can someone help me please?

thanks in advance

How did you customise the ui like this?

What i’d like to achieve in the end is something like this:

I am currently using a variation of the BP Magic-Script - v0.4.2 > β˜… By Ski-lleR β˜…
But it’s not doing what I need/want.

If anyone could give me pointers of help I would be forever grateful!

Revised MBP YA Magic-Script that does more stuff too. v2.7

β€’ Fixed Stupid Issue where it was resetting it’s filenames midway through. :man_facepalming:
β€’ Re-arranged and clarified some of the settings/config options
β€’ Added some more examples to the config/settings options
β€’ Added option to NOT sort by Artist First/Last Initial. **

** $set(_orderTypeForArtist,3)
This skips …/A/Artist… and goes straight to …/Artist
I have not checked this function against many other options, it feels like it’s working as intended though.

The header is Chopped Off - It won’t fit in a single post. The Rest is in the next post.

$noop(β˜… MBP YA Magic-Script that does more stuff too. - v2.7  - amd/17500mph β˜…)
$noop(β˜…											β˜…)
$noop(β˜… INSERT COIN β˜…)
 
$noop(Configuration Section - 0-Disable / 1-Enable)

$noop(β˜… For Development Only -  β˜…)
$noop(β˜… Variable Settings in Subsections      - β˜…)
$noop(β˜…  - Audio Metrics Only at this Time    - β˜…)
$noop(β˜… This should be 0 for proper function! - β˜…)
$set(_devMode,0)

$noop(β˜… For Sort Only. No Filename Formatting - β˜…)
$noop(β˜…   Usually for When Saving from Left   - β˜…)
$noop(β˜…   It's RARE that you would want this  - β˜…)
$noop(β˜…   Usually for When Saving from Left   - β˜…)
$set(_quickNoNameFormat,0)


$noop(β˜… GLOBAL SETTINGS - Things you're likely to want to configure β˜…)

$noop(  /Licorice Pizza/B/B-52s, The/EP/Wild Planet∢ 2007 Remix EP [CD] [2007] [Promotion] [Planet Clique] [SSMCD005] )
$noop(  /Licorice Pizza/B/B-52s, The/EP/Wild Planet∢ 2007 Remix EP [CD] [_showDate] [_showReleaseStatus] [_showRecordLabel] [_showCatalogueNumber] )
$noop(Configuration Section - 0-Disable / 1-Enable)
$set(_showRecordLabel,1)
$set(_showDate,1)
$set(_showReleaseStatus,1)
$set(_showCatalogueNumber,1)

$noop(β˜… Values Included before File Ext. β˜…)
$noop(  01. Quiche Lorraine [S-Express remix][5∢54][320 44100KHz CBR 2ch].m4a  )
$noop(  01. Quiche Lorraine [S-Express remix][_showTime][_showBandwidth].m4a   )
$if($eq(%_quickNoNameFormat%,1),$set(_showTime,0),$set(_showTime,1))
$if($eq(%_quickNoNameFormat%,1),$set(_showBandwidth,0),$set(_showBandwidth,1))


$noop(β˜… Sort orderTypeForRoot                      β˜…)
$noop(β˜… ~/Music/Last.fm Genre/A/Artist/AlbumTitle/ β˜…)
$noop(β˜…  1: Category [Last.fm.ng]   β˜…)
$noop(β˜… ~/Music/A/Artist/AlbumTitle/β˜…)
$noop(β˜…  2: Artist first letter     β˜…)
$set(_orderTypeForRoot,2)

$noop(β˜… Sort orderTypeForArtist                β˜…)
$noop(β˜…  1: First letter of first name         β˜…)
$noop(β˜… ~/Music/M/Music Artist/AlbumTitle/     β˜…)
$noop(β˜…  2: First letter of last name          β˜…)
$noop(β˜… ~/Music/A/Artist, Music/AlbumTitle/    β˜…)
$noop(β˜…  3: No Sub-Separation by Artist Initialβ˜…)
$noop(β˜… ~/Music/Artist, Music/AlbumTitle/      β˜…)
$set(_orderTypeForArtist,2)

$noop(β˜… How to designate Complete Albums that contain multiples/extras of at least 1 Track      β˜…)
$noop(β˜… 1  They are Sorted as Complete. will show silver starred but not Gold icon on the Right β˜…)
$noop(β˜… 0, They are Sorted as InComplete β˜…)

$set(_extraTrackHandling,1)

$noop(β˜… 1  Earlier in the Sort Artist Diversion?    β˜…)
$set(_earlierLevelArtistSeparation,0)
$noop(β˜… 0  Earlier in the Sort Incomplete Diversion?β˜…)
$set(_earlierPresortForIncompletes,1)

$noop(β˜… Do you want separation by type / extension at the Root Level?β˜…)
$noop(β˜… ~/Music/MP3/AlbumTitle/ - ~/Music/FLAC/AlbumTitle/ - ~/Music/M4A/AlbumTitle/ - ~/Music/WNA/AlbumTitle/ β˜…)
$set(_rootLevelTypeSeparation,0)   

$noop(β˜… Do you want separatation by type / extension at the Album Level?                                      β˜…)
$noop(β˜… ~/Music/AlbumTitle/MP3/ - ~/Music/AlbumTitle/FLAC/ - ~/Music/AlbumTitle/M4A - ~/Music/AlbumTitle/WNA/ β˜…)
$set(_albumLevelTypeSeparation,1)

$noop(β˜… Do you want the Album Title added before the type / extension after the Album Level?                         β˜…)
$noop(β˜… ~/Music/AlbumTitle/AlbumTitle MP3/ - ~/Music/AlbumTitle/AlbumTitle FLAC/ - ~/Music/AlbumTitleAlbumTitle /M4A β˜…)
$set(_albumNameAtTypeSeparation,1)

$noop(β˜… Root Level Sort Against Select Genre Values. β˜…)
$noop(β˜… ~/Music/GenreSubSortDirectory/AlbumTitle/AlbumTitle MP3/Single/ - ~/Music/GenreSubSortDirectory/AlbumTitle/AlbumTitle FLAC/EP/ β˜…)
$set(_isSubSort,1)

$noop(Album Name/EP/Single/Live/Album etc.)
$noop(β˜… ~/Music/AlbumTitle/AlbumTitle MP3/Single/ - ~/Music/AlbumTitle/AlbumTitle FLAC/EP/ β˜…)
$set(_separateByTypeInArtistDirectory,1)

$noop(β˜… Do you want Tribute and Cover Albums Placed with Artist being attributed? β˜…)
$noop(β˜… ~/Music/AlbumTitle/AlbumTitle MP3/Cover/ - ~/Music/AlbumTitle/AlbumTitle FLAC/Tribute/ β˜…)
$noop(β˜… Requires coverTributeSort tag and albumartistsort Tags β˜…)
$noop(Set a coverTributeSort tag value of β€œTribute” or β€œCover”.)
$noop(Enter the associated Artist in the AlbumArtistSort as tag.)
$set(_altArtistSort,1)

$set(_separateAlbum,0) $noop(Albums in SubDirectory as well)
$noop(β˜… ~/Music/A/Artist/AlbumTitle, ~/Music/A/Artist/Albums/AlbumTitle β˜…)

$set(_showTrackArtistSeparation,0) $noop(Breakdown by Artist within Album ** Special Case Use / Usually Left Side Compilations)
$noop(β˜… ~/Music/A/Artist/AlbumTitle/Artist/Track, ~/Music/A/Artist/Albums/AlbumTitle/Artist/Track β˜…)

$set(_compilationsGSubDirectory,Compilations/)
$noop(β˜… ~/Music/Compilations/  β˜…)

$noop(β˜… SOUNDTRACK/VARIOUS DIRECTORY β˜…)
$set(_soundTracksDirectory,Soundtrack/)
$set(_variousArtistsDirectory,Various/)
$set(_audiobooksDirectory,Audiobook/)
$set(_incompleteDirectory,Partial)
$set(_podcastSubDirectory,Podcast/)

$noop(β˜… Multi-Disc β˜…)

$noop(β˜… ~/Music/A/Artist, Music/AlbumTitle/Disc01/01 - Tracklist β˜…)
$set(_useSubDiscDirectory,1)

$noop(β˜… ~/Music/A/Artist, Music/AlbumTitle/01 - Tracklist ***SKIP SubDiscDirectory if only one Medium in Realease β˜…)
$set(_mergeDiscWhenNotUsingSubDirectory,0)

$set(_showDiscSubtitle,1)
$set(_nameForTypeCD,Disc)
$set(_nameForTypeVinyl,Side)

$noop(β˜… ~/Music/A/Artist, Music/AlbumTitle/A1 ,A2 ,B1, B2 Tracklist - β˜…)
$set(_useMusicBrainzStyleForVinylTrack,1)

$noop(β˜… Custom Subdirectory Titles at Artist Level β˜…)
$noop(β˜… ~/Music/A/Artist, Music/EP/AlbumTitle ~/Music/A/Artist, Music/Live/AlbumTitle β˜…)

$set(_albumSubDirectory,Albums/)
$set(_compilationsASubDirectory,Compilation/)
$set(_coverSubDirectory,Cover/)
$set(_tributeSubDirectory,Tribute/)
$set(_singlesSubDirectory,Singles/)
$set(_liveSubDirectory,Live/)
$set(_epSubDirectory,EP/)
$set(_broadcastSubDirectory,β€’Broadcast/)
$set(_interviewSubDirectory,Interview/)
$set(_videoSubDirectory,Video/)
$set(_otherSubDirectory,Others/)
$set(_dupesDirectory,β€’ Duplicates/)
$set(_exportDirectory,β€’ Exports/)
$set(_extDirectory,%_extension%/)

$noop(β˜… _subSortXXXX are pretty specific        β˜…)
$noop(β˜… breakdowns that require setting a value β˜…)
$noop(β˜… with a tag titled    %genresort%        β˜…)
$noop(β˜… These can be ignored or reduced, just   β˜…)
$noop(β˜… keep at least one for an example incase β˜…)
$noop(β˜… You want to sort like this later.       β˜…)
$noop(β˜… /LicoricePizza/_subSortXXXX/ ....       β˜…)

$set(_subSortGame,β€’Arcade/)
$set(_subSortDJBits,β€’DJBits/)
$set(_subSortClassical,Classical/)
$set(_subSortDemento,Dementia/)
$set(_subSort12Inch,β€’12 Inch Mix/)
$set(_subSortDisney,Disney/)
$set(_subSortPodcast,Podcast/)
$set(_subSortInterview,β€’Interview/)
$set(_subSortBroadcast,Broadcast/)
$set(_subSortReserved,β€’Singles Candidates/)
$set(_subSortPreTag,β€’No MBID/)
$set(_subSortHoliday,Holiday/)
$set(_subSortCountry,Country/)
$set(_subSortBlues,Blues/)
$set(_subSortJazz,Jazz/)
$set(_subSort2Oct,Spooktacular/)
$set(_subSort2Nov,Fallback/)
$set(_subSort2Dec,Here Comes Santa/)
$set(_subSort2Jan,Wintertime/)
$set(_subSort2Feb,Will You Be My Valentine?/)
$set(_subSort2Mar,Spring is in the Air/)
$set(_subSort2Apr,Foolish/)
$set(_subSort2May,Maybe/)
$set(_subSort2June,SumSumSummertime/)
$set(_subSort2July,Fireworks & Stuff/)
$set(_subSort2Aug,SumSumSummertime/)
$set(_subSort2Sept,SumSumSummertime/)

$noop(β˜… Detect Genre/SubSort Destinations for above values β˜…)

$if($in(%genresort%,Holiday),$set(_subSortDirectory,%_subSortHoliday%))
$if($in(%genresort%,*-*),$set(_subSortDirectory,%_subSortReserved%))
$if($in(%genresort%,***),$set(_subSortDirectory,%_subSortPreTag%))
$if($in(%genresort%,Novelty),$set(_subSortDirectory,%_subSortDemento%))
$if($in(%genresort%,DJ Bits),$set(_subSortDirectory,%_subSortDJBits%))
$if($in(%genresort%,Humo),$set(_subSortDirectory,%_subSortDemento%))
$if($in(%genresort%,Demento),$set(_subSortDirectory,%_subSortDemento%))
$if($in(%genresort%,Comedy),$set(_subSortDirectory,%_subSortDemento%))
$if($in(%genresort%,FuMP),$set(_subSortDirectory,%_subSortDemento%))
$if($in(%genresort%,Game),$set(_subSortDirectory,%_subSortGame%))
$if($in(%genresort%,Disney),$set(_subSortDirectory,%_subSortDisney%))
$if($in(%genresort%,odcast),$set(_subSortDirectory,%_subSortPodcast%))
$if($in(%genresort%,nterview),$set(_subSortDirectory,%_subSortInterview%))
$if($in(%genresort%,roadcast),$set(_subSortDirectory,%_subSortBroadcast%))
$if($in(%genresort%,12 Inch),$set(_subSortDirectory,%_subSort12Inch%))
$if($in(%genresort%,Classical),$set(_subSortDirectory,%_subSortClassical%))
$if($in(%genresort%,Country),$set(_subSortDirectory,%_subSortCountry%))
$if($in(%genresort%,Spook),$set(_subSort2Directory,%_subSort2May%))
$if($in(%genresort%,Fall),$set(_subSort2Directory,%_subSort2Nov%))
$if($in(%genresort%,Summer),$set(_subSort2Directory,%_subSort2June%))
$if($in(%genresort%,Firew),$set(_subSort2Directory,%_subSort2July%))
$if($in(%genresort%,Fool),$set(_subSort2Directory,%_subSort2Apr%))
$if($in(%genresort%,Maybe),$set(_subSort2Directory,%_subSort2May%))
$if($in(%genresort%,Spring),$set(_subSort2Directory,%_subSort2Mar%))
$if($in(%genresort%,Santa),$set(_subSort2Directory,%_subSort2Dec%))
$if($in(%genresort%,Blues),$set(_subSortDirectory,%_subSortBlues%))
$if($in(%genresort%,Jazz),$set(_subSortDirectory,%_subSortJazz%))

$noop(####################### Scratch Space ######################)
$noop(β˜… Unless you're changing appearances, there isn't really anything to do past here β˜…)
$noop(####################### END SETTINGS #######################)


$noop(########## DETECT MUSIC TYPE ###############################)

$noop(β˜… Detect Album β˜…)
$if($in(%releasetype%,album),
  $set(_isAlbum,1)
)
$noop(β˜… Detect Single β˜…)
$if($in(%releasetype%,single),
  $set(_isSingle,1)
)
$noop(β˜… Detect Live β˜…)
$if($in(%releasetype%,live),
  $set(_isLive,1)
)
$noop(β˜… Detect EP β˜…)
$if($in(%releasetype%,ep),
  $set(_isEP,1)
)
$noop(β˜… Detect Broadcast β˜…)
$if($in(%releasetype%,broadcast),
  $set(_isBroadcast,1)
)
$noop(β˜… Detect Interview β˜…)
$if($in(%releasetype%,interview),
  $set(_isInterview,1)
)
$noop(β˜… Detect Artist Compilation β˜…)
$if($in(%releasetype%,compilation),
  $set(_isArtistCompil,1)
)
$noop(β˜… Detect Audiobook β˜…)
$if($in(%releasetype%,audiobook),
  $set(_isAudiobook,1)
)
$noop(β˜… Detect Other β˜…)
$if($in(%releasetype%,other),
  $set(_isOther,1)
)
$noop(β˜… Detect Tribute β˜…)
$if($in(%coverTributeSort%,Tribute),
  $set(_isTribute,1)
)
$noop(β˜… Detect Cover β˜…)
$if($in(%coverTributeSort%,Cover),
  $set(_isCover,1)
)
$noop(β˜… Detect Podcast β˜…)
$if($in(%genre%,Podcast),
  $set(_isPodcast,1)
)
$noop(β˜… Detect Soundtrack β˜…)
$if($in(%releasetype%,soundtrack),
  $set(_isSoundTrack,1)
)
$noop(β˜… Detect BitRate Split β˜…)
$if($in(%BitRateSplit%,Yes),
  $set(_addBitRate,1)
)
$noop(β˜… Detect Incomplete β˜…)
$if($eq($is_complete(),0),
  $set(_isIncomplete,1)
)
$noop(β˜… Detect Video β˜…)
$if($eq($is_video(),0),
  $set(_isVideo,1)
)
$noop(β˜… Detect Various Artist β˜…)
$if($eq(%albumartist%,Various Artists),
  $set(_isVarious,1)
)
$noop(β˜… Re-detect Compilation Type β˜…)
$if($eq(%compilation%,1),
  $set(_isGlobalCompil,1)
)
$noop(β˜… Detect Global Compilation β˜…)
$if($eq(%_isGlobalCompil%,1), $set(_isArtistCompil,0)
)
$noop(β˜… Get Track Length β˜…)
$if($eq(%_showTime%,1),
  $set(_trackLength,%_length%)
)
$noop(β˜… Drop Unused Placeholder Tags β˜…)
$if($eq(%title%,Title),$delete(title)$delete(titlesort))
$if($eq(%subtitle%,Subtitle),$delete(subtitle))
$if($eq(%discsubtitle%,DiscSubtitle),$delete(discsubtitle))
$if($eq(%artists%,Artist;AdditionalArtists),$delete(artists))
$if($eq(%artistssortorder%,Artist),$delete(artistssortorder))
$if($eq(%album%,Album),$delete(album)$delete(albumsort)$delete(albumartistsort)$delete(albumartist))
$if($eq(%media%,Media),$delete(media))
$if($eq(%label%,Label),$delete(label))
$if($eq(%catalognumber%,Cat#),$delete(catalognumber))

$noop(########## Start File Naming Structure Variables ###########)
$noop(sorted by artist place holder)
$noop(β€’ByBitRate/%bitrate%)
$noop(β˜… Typography on file naming only β˜…)
$set(_titleForFilename,$if2(%titlesort%,%title%))
$set(_albumForFilename,$if2(%albumsort%,%album%))

$set(_discsubtitleForFilename,%discsubtitle%)
$set(_albumartistForFilename,$if2(%albumartist%,%artist%))
$set(_artistForFilename,%artist%)
$set(_albumartistsortForFilename,$if2(%albumartistsort%,%artistsort%,%artist%))
$set(_artistsortForFilename,$if2(%artistsort%,%artist%))

$noop(########## Start TAG Manipulation ##########################)
$noop(β˜… Organize artist by alphabetical Directories excluding leading The β˜…)
$set(albumartist,$if($eq($left(%albumartist%,4),The ),%albumartistsort%,%albumartist%))
$noop($set(undersc0riginalFileName,%_filename%))

$noop(########## Start TAG Formatting  ###########################)
$noop(β˜… Typography for tags: changes will affect tags on media β˜…)

$noop(β˜… ... ➑ …)
$set(album,$replace(%album%,...,…))
$set(title,$replace(%title%,...,…))
$set(discsubtitle,$replace(%discsubtitle%,...,…))

$noop(β˜… No. ➑ β„–)
$set(album,$replace(%album%, [Nn]o.\\s*\(\\d\), β„–\\1))
$set(title,$rreplace(%title%, [Nn]o.\\s*\(\\d\), β„–\\1))
$set(discsubtitle,$replace(%discsubtitle%, [Nn]o.\\s*\(\\d\), β„–\\1))

$noop(β˜… [digit]" ➑ [digit]β€³)
$set(discsubtitle,$rreplace(%discsubtitle%,\(\\d\)",\\1''))

$noop(β˜… "12" Vinyl" ➑ "12 Inch Vinyl")
$set(media,$rreplace(%media%,\(\\d\)",\\1 Inch))
$set(album,$rreplace(%album%,\(\\d\)",\\1 Inch))
$set(title,$rreplace(%title%,\(\\d\)",\\1 Inch))

$noop(β˜… "something" ➑ β€œsomething” single quote for server/samba)
$set(albumartist,$rreplace(%albumartist%,"\(.*?\)",'\\1'))
$set(artist,$rreplace(%artist%,"\(.*?\)",'\\1'))
$set(albumartistsort,$rreplace(%albumartistsort%,"\(.*?\)",'\\1'))
$set(artistsort,$rreplace(%artistsort%,"\(.*?\)",'\\1'))
$set(album,$rreplace(%album%,"\(.*?\)",'\\1'))
$set(title,$rreplace(%title%,"\(.*?\)",'\\1'))
$set(discsubtitle,$rreplace(%discsubtitle%,"\(.*?\)",'\\1'))

$noop(β˜… # ➑ β™―)
$set(_titleForFilename,$replace(%_titleForFilename%,#,β™―))
$set(_albumForFilename,$replace(%_albumForFilename%,#,β™―))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,#,β™―))

$noop(β˜… ;: ➑ h, m,)
$set(_trackLength,$replace(%_trackLength%,:,∢))

$noop(β˜… : ➑ ∢)
$set(_titleForFilename,$replace(%_titleForFilename%,:,∢))
$set(_albumForFilename,$replace(%_albumForFilename%,:,∢))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,:,∢))
$set(_artistForFilename,$replace(%_artistForFilename%,:,∢))
$set(_albumartistForFilename,$replace(%_albumartistForFilename%,:,∢))
$set(_artistsortForFilename,$replace(%_artistsortForFilename%,:,∢))
$set(_albumartistsortForFilename,$replace(%_albumartistsortForFilename%,:,∢))

$noop(β˜… ? ➑ ⁇)
$set(_titleForFilename,$replace(%_titleForFilename%,?,⁇))
$set(_albumForFilename,$replace(%_albumForFilename%,?,⁇))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,?,⁇))
$set(_artistForFilename,$replace(%_artistForFilename%,?,⁇))
$set(_artistsortForFilename,$replace(%_artistsortForFilename%,?,⁇))

$set(_titleForFilename,$replace(%_titleForFilename%,|,οΏ¨))
$set(_albumForFilename,$replace(%_albumForFilename%,|,οΏ¨))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,|,οΏ¨))

$set(_titleForFilename,$replace(%_titleForFilename%,>,>))
$set(_albumForFilename,$replace(%_albumForFilename%,>,>))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,>,>))

$set(_titleForFilename,$replace(%_titleForFilename%,<,<))
$set(_albumForFilename,$replace(%_albumForFilename%,<,<))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,<,<))

$set(_titleForFilename,$replace(%_titleForFilename%,*,✱))
$set(_albumForFilename,$replace(%_albumForFilename%,*,✱))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,*,✱))
$set(_artistForFilename,$replace(%_artistForFilename%,*,✱))
$set(_albumartistForFilename,$replace(%_albumartistForFilename%,*,✱))
$set(_artistsortForFilename,$replace(%_artistsortForFilename%,*,✱))
$set(_albumartistsortForFilename,$replace(%_albumartistsortForFilename%,*,✱))

$set(_titleForFilename,$replace(%_titleForFilename%,&,οΌ†))
$set(_albumForFilename,$replace(%_albumForFilename%,&,οΌ†))
$set(_discsubtitleForFilename,$replace(%_discsubtitleForFilename%,&,οΌ†))
$set(_artistForFilename,$replace(%_artistForFilename%,&,οΌ†))
$set(_albumartistForFilename,$replace(%_albumartistForFilename%,&,οΌ†))
$set(_artistsortForFilename,$replace(%_artistsortForFilename%,&,οΌ†))
$set(_albumartistsortForFilename,$replace(%_albumartistsortForFilename%,&,οΌ†))
$noop(β˜… For Development Only - Variable Settings in Subsections β˜…)
$noop(β˜… Where Available - Audio Metrics Only at this Time β˜…)

$noop(########### Audio Metrics Setup  ###########################)
$noop(########### DevMode Values Only ############################)

$set(_devMode,0) $noop(Use Standin Data.)

$set(_biitrate,71.426)
$set(_saample_rate,44100)
$set(_biits_per_sample,16)
$set(_chaannels,2)
$set(_tiitle,My Great Score)
$noop(########### CONFIRM DevMode is Disabled for Live Use ########)

$noop(############## Determine Bit Rate Integer Value #############)

$if($eq(%_devMode%,1),FileBit %_biitrate% ---)

$if($eq(%_devMode%,1),$set(_intBitRate,$rreplace(%_biitrate%,\\.\\d*\$,)),$set(_intBitRate,$rreplace(%_bitrate%,\\.\\d*\$,)))

$if($eq(%_devMode%,1),IntBit %_intBitRate% ---)

$if($eq(%_devMode%,1),$set(_bitRateSpeed,%_saample_rate%KHz),$set(_bitRateSpeed,%_sample_rate%KHz))
$if($eq(%_devMode%,1),$set(_bitsPerSample,[%_biits_per_sample%]bit),$set(_bitsPerSample,[%_bits_per_sample%]bit))
$if($eq(%_devMode%,1),$set(_audioChannels,%_chaannels%ch),$set(_audioChannels,%_channels%ch))
$if($eq(%_devMode%,1),$set(_titleForFilename,%_tiitle%),$set(_titleForFilename,%_titleForFilename%))

$set(_bitRateType,$if($eq_any(%_intBitRate%,320,256,224,192,160,128,112,96,80,64,48,40,32,24,16,8),CBR$set(_cbrRateValue,%_intBitRate%)$set(_fileCBRRate,%_intBitRate%),VBR$set(_vbrRateValue,%_intBitRate%)))

$noop(Bitrate factors of 8.0 are most likely CBR with the remainder being VBR)

$if($eq(%_bitRateType%,VBR),
$if($gt(%_vbrRateValue%,339),$set(_fileVBRRate,320+),
$if($gt(%_vbrRateValue%,319),$set(_fileVBRRate,320),
$if($gt(%_vbrRateValue%,260),$set(_fileVBRRate,V0+),
$if($gt(%_vbrRateValue%,220),$set(_fileVBRRate,V0),
$if($gt(%_vbrRateValue%,191),$set(_fileVBRRate,V1),
$if($gt(%_vbrRateValue%,170),$set(_fileVBRRate,V2),
$if($gt(%_vbrRateValue%,150),$set(_fileVBRRate,V3),
$if($gt(%_vbrRateValue%,140),$set(_fileVBRRate,V4),
$if($gt(%_vbrRateValue%,130),$set(_fileVBRRate,V5),
$if($gt(%_vbrRateValue%,120),$set(_fileVBRRate,V6),
$if($gt(%_vbrRateValue%,95),$set(_fileVBRRate,V7),
$if($gt(%_vbrRateValue%,69),$set(_fileVBRRate,V8),
$if($gt(%_vbrRateValue%,44),$set(_fileVBRRate,V9),
$set(_fileVBRRate,%_intBitRate%)
))))))))))))))

$noop(######### File Naming Structure Variables Complete #########)

$noop(β˜… Pathname Generation Starts Here β˜…)

$noop(β˜… Root level Path β˜…)
$noop(   root = '/Volumes/Drive/Music/ ... [Destination Directory Setting])
$noop(   rootLevelExport Separation/%_exportssDirectory%/MP3/Artist/Album ...)
$if($eq(%_rootLevelExportsSeparation%,1),%_exportDirectory%,)

$noop(   rootLevelDuplicate Separation/%_dupesDirectory%/MP3/Artist/Album ...)
$if($eq(%_rootLevelDupeSeparation%,1),%_dupesDirectory%,)

$noop(β˜… Separate by Format at root directory β˜…)
$noop(   rootLevelPath/MP3/Artist/Album ...)
$if($eq(%_rootLevelTypeSeparation%,1),$upper(%_extension%),)

$noop(β˜… Separate by _setSubSort against Genre tag values β˜…)
$if($eq(%_isSubSort%,1),%_subSortDirectory%%_subSort2Directory%)

$noop(   Earlier Incomplete Separation for Sorting ...)
$if($eq(%_earlierPresortForIncompletes%,1),$if($eq($is_complete(),0),$if($lt($matchedtracks(),%_totalalbumtracks%),$if($and(%_isIncomplete%,$not($in(%SavePerfectAnyway%,yes))), - %_incompleteDirectory%,))),$if($and(%_isIncomplete%,$not($in(%SavePerfectAnyway%,yes))), - %_incompleteDirectory%,))
$if($in(%SaveIncompleteAnyway%,yes),%_incompleteDirectory%)/
$if($eq(%_earlierLevelArtistSeparation%,1),%_artistForFilename%/)

$noop(β˜… Soundtrack in custom directory ,after soundtracksDirectory?? β˜…)
$noop(   root/*/Audio Books/Title ...)
$noop(   root/*/Soundtracks/Title ...)
$noop(   root/*/Podcasts/Title ...)
$if(%_isSoundTrack%,%_soundTracksDirectory%$left($swapprefix($if2(%albumsort%,%album%),A,An,The),1)/,/
$if(%_isAudiobook%,%_audiobooksDirectory%$left($swapprefix($if2(%albumsort%,%album%),A,An,The),1)/,/)
$if(%_isPodcast%,%_podcastDirectory%$left($swapprefix($if2(%albumsort%,%album%),A,An,The),1)/,/)

$noop(β˜… Various in custom directory β˜…)
$noop(root/<*>/Various)

$if(%_isVarious%,%_variousArtistsDirectory%$left($swapprefix($if2(%albumsort%,%album%),A,An,The),1)/,/
$if(%_isGlobalCompil%,%_compilationsGSubDirectory%$left($swapprefix($if2(%albumsort%,%album%),A,An,The),1)/,/)

$noop(β˜… Order root by category β˜…)
	$if($eq(%_orderTypeForRoot%,1),
	$if2(%albumgrouping%,Unknown)
	)/

$noop(β˜… Order root by artist β˜…)
$noop(root/<*>/<Last.FM=>/)
$noop(root/<*>/D/)

$if($eq(%_orderTypeForRoot%,2),
	$if($eq(%_orderTypeForArtist%,1),$upper($firstalphachar($if2(%_albumartistForFilename%,%_artistForFilename%),#1)),
	$if($eq(%_orderTypeForArtist%,2),$if(%_isGlobalCompil%,,$upper($firstalphachar($if2(%_albumartistsortForFilename%,%_artistsortForFilename%),#2)))
	$if($eq(%_orderTypeForArtist%,3),),../
	)))/


$noop(β˜… Artist with first letter of first name β˜…)
$noop(root/<*>/B/The B-52's)
$if($eq(%_orderTypeForArtist%,1),$if2(%_artistSort%,%_albumartistForFilename%,%_artistForFilename%))/

$noop(β˜… Artist with first letter of last name β˜…)
$noop(root/<*>/B/B-52's, The)
$if($eq(%_orderTypeForArtist%,2),$if(%_isGlobalCompil%,,$if2(%_albumartistsortForFilename%,%_artistsortForFilename%)))/

$noop(β˜… Order root by category β˜…)
$if($eq(%_orderTypeForArtist%,3),)/

$noop(β˜… If Using Alternate Artists Directory For Covers & Tributes  **Uses Order for Album Artist tag β˜…)

	$noop(root/<*>/O/Oingo Boingo/[Tributes]/DeadBandsParty)
	$if($eq_all(%coverTributeSort%,%_altArtistSort%,%_isTribute%,1),
	$if2(%_artistSort%,%_albumartistForFilename%,%_artistForFilename%)
	)/

	$noop(root/<*>/D/DEVO/[Covers]/Devolution)
	$if($eq_all(%coverTributeSort%,%_altArtistSort%,%_isCover%,1),
	$if2(%_artistSort%,%_albumartistForFilename%,%_artistForFilename%)
	)/
	$noop(β˜… Organize by type β˜…)
	$noop(root/<*>/Y/Yes/[Live]/90125 Live)
	$noop(root/<*>/Y/Yes,/90125)
	$if($eq(%_separateByTypeInArtistDirectory%,1),
		$if($eq(%_isArtistCompil%,1),%_compilationsASubDirectory%,
			$if($eq(%_isLive%,1),%_liveSubDirectory%,
				$if($eq(%_isCover%,1),%_coverSubDirectory%,
					$if($eq(%_isTribute%,1),%_tributeSubDirectory%,
						$if($eq(%_isEP%,1),%_epSubDirectory%,
							$if($eq(%_isSingle%,1),%_singlesSubDirectory%,
								$if($eq(%_isBroadcast%,1),%_broadcastSubDirectory%,
							   	$if($eq(%_isInterview%,1),%_interviewSubDirectory%,
										$if($eq(%_isVideo%,1),%_videoSubDirectory%,
											$if($eq(%_isOther%,1),%_otherSubDirectory%,
												$if($eq(%_isAlbum%,1),
													$if($eq(%_separateAlbum%,1),%_albumSubDirectory%))

	)))))))))))))

$noop(root/<*>/B/B-52's, The]/Bouncing off the Satellites/ )
%_albumForFilename%
$noop(β˜… Bouncing off the Satellites [Media-Type]/ β˜…)
$noop($if($ne(%media%,CD),$if(%media%,[$rreplace(%media%,["β€³], Inch)])))
$if(%media%, [$title(%media%]),)

$noop($if($and(%media%,$ne(%media%,CD)),$if($in(%media%,Vinyl),$title( [%media%])),$upper( [%media%])))

$noop(β˜… Bouncing off the Satellites [Vinyl] [YEAR]/ β˜…)
$if($eq(%_showDate%,1),$if($if2(%date%,%originalyear%,%originaldate%), [$left($if2(%date%,%originalyear%,%originaldate%),4)],))
$noop(β˜… Bouncing off the Satellites [Vinyl] [1986] [Release Status]/ β˜…)
$if(%releasestatus%,$if($eq(%_showReleaseStatus%,1),$title( [%releasestatus%])))

$noop(β˜… Bouncing off the Satellites [Vinyl] [1986] [Official] [Label]/ β˜…)
$if(%label%,$if(%_showRecordLabel%, $if(%label%,$title([%label%]))))

$noop(β˜… Bouncing off the Satellites [Vinyl] [1986] [Official] [MCA] [CAT-Number]/ β˜…)
$if(%catalognumber%,$if($eq(%_showCatalogueNumber%,1),$title( [%catalognumber%])))

$noop(β˜… Bouncing off the Satellites [Vinyl] [1986] [Official] [MCA] [AB-DC001]/ β˜…)
$noop(β˜… Bouncing off the Satellites [Vinyl] [1986] [Official] [MCA] [AB-DC001] - Incomplete/ β˜…)

$if($eq(%_extraTrackHandling%,1),$if($eq($is_complete(),0),$if($lt($matchedtracks(),%_totalalbumtracks%),$if($and(%_isIncomplete%,$not($in(%SavePerfectAnyway%,yes))), - %_incompleteDirectory%,))),$if($and(%_isIncomplete%,$not($in(%SavePerfectAnyway%,yes))), - %_incompleteDirectory%,)
)/
$noop(β˜… Bouncing off the Satellites [Vinyl] [1986] [Official] [MCA] [AB-DC001]/ MP3 / β˜…)
$noop(β˜… Bouncing off the Satellites [Vinyl] [1986] [Official] [MCA] [AB-DC001]/ Bouncing off the Satellites MP3 / β˜…) 

$if($eq(%_albumLevelTypeSeparation%,1),$if($eq(%_albumNameAtTypeSeparation%,1),%_albumForFilename%,)$if($eq(%_addBitRate%,1), %_fileVBRRate%%_fileCBRRate% %_bitRateType%)$upper( %_extension%))/

$noop(β˜… One Last Option to Sort By Author -within- a Left Side Album Compilation/ β˜…)
$if(%artist%,$if($eq(%_showTrackArtistSeparation%,1),$title(%artist%)))

$noop(β˜… Bouncing off the Satellites [Vinyl] [1986] [Official] [MCA] [AB-DC001]/ .../ Disc # β˜…)
$if($gt(%totaldiscs%,1),$noop(
	)$if($lt(%totaldiscs%,10),$set(_discnumber, %discnumber%),$set(_discnumber,$num(%discnumber%,2)))$noop(
	)$if($in(%media%,Vinyl),$noop(
		)$set(_nameForDiscDirectory,@OSLASH@@OBRACKET@%_nameForTypeVinyl%%_discnumber%@CBRACKET@),$noop(
		)$set(_nameForDiscDirectory,@OSLASH@@OBRACKET@%_nameForTypeCD%%_discnumber%@CBRACKET@))$noop(
		)$if($and(%_discsubtitleForFilename%,$eq(%_showDiscSubtitle%,1)),$set(_nameForDiscDirectory,%_nameForDiscDirectory% - %_discsubtitleForFilename%))$noop(
		)$if($eq(%_useSubDiscDirectory%,1),$noop(
			)$set(_nameForDiscDirectory,$replace(%_nameForDiscDirectory%,@OSLASH@@OBRACKET@,/))$noop(
			)$set(_nameForDiscDirectory,$replace(%_nameForDiscDirectory%,@CBRACKET@,)),$noop(
			)$if($eq(%_mergeDiscWhenNotUsingSubDirectory%,1),$noop(
				)$unset(_nameForDiscDirectory),$noop(
				)$set(_nameForDiscDirectory,$replace(%_nameForDiscDirectory%,@OSLASH@@OBRACKET@,[))$noop(
			)$set(_nameForDiscDirectory,$replace(%_nameForDiscDirectory%,@CBRACKET@,]))$noop(
		))$noop(
	))$noop(
)$if(%_nameForDiscDirectory%,%_nameForDiscDirectory%))/

$noop(β˜… Track # Title --%_filebr% -- %bitrate% -- %BRType% -- %BrVBR% --  β˜…)
$if($in(%media%,Vinyl),$noop(
	)$if($eq(%_useMusicBrainzStyleForVinylTrack%,1),$noop(
		)$if(%_musicbrainz_tracknumber%,%_musicbrainz_tracknumber%. )$noop(
	)),$noop(
	)$if(%tracknumber%,$if($gt(%totaldiscs%,1),$if($and($eq(%_useSubDiscDirectory%,0),$eq(%_mergeDiscWhenNotUsingSubDirectory%,1)),%discnumber%))$num(%tracknumber%,2). ))

$noop(β˜… GAME OVER β˜…)

$if($eq(%_quickNoNameFormat%,0),%_titleForFilename%,%_filename%)

$noop(β˜… Insert Coin for Extra Metrics β˜…)

[%_trackLength%]

$if($eq(%_quickNoNameFormat%,0),$if($eq(%_showBandwidth%,1),[%_fileCBRRate%%_fileVBRRate% %_bitRateSpeed% %_bitRateType% %_audioChannels%],$if($eq(%_showBandwidth%,1),[%_fileCBRRate%%_fileVBRRate% %_bitRateType%])))

$noop(β˜… 00 CREDITS β˜…)

This is the non-truncated text for the script in the previous post. This belongs at the TOP of the file. This does not make a difference in functionality, but it should stay with it.

$noop(β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…)
$noop(β˜… MBP YA Magic-Script that does more stuff too. - v2.7 -  amd/17500mph β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… Here is a script for music renaming in MusicBrainz Picard            β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… Note: Destination Director Setting                                   β˜…)
$noop(β˜…       /Volumes/3TB/Licorice Pizza                                    β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… Features :                                                           β˜…)
$noop(β˜…                                                                      β˜…)
$noop(β˜…   Individualy Selectable Root Directory Organization Options:        β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… β€’ Directories by [A]rtist Name / [N]ame, Artist or last.fm** categoryβ˜…)
$noop(β˜… β€’ subDirectory for each main type [Album/Single/EP...]               β˜…)
$noop(β˜… β€’ Separate Root directory for compilations [!various]                β˜…)
$noop(β˜… β€’ Single Artist Compilations go in Artist Directory                  β˜…)
$noop(β˜… β€’ Root directory Audio Books, Podcasts, Others                       β˜…)
$noop(β˜… β€’ Root directory Genre PreSort                                       β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜…  ~/MusicRoot/[O]/Oingo Boingo/[Artist Compilations]/                 β˜…)
$noop(β˜…  ~/MusicRoot/Compilations/K-Tel Hits of the 1980s Vol. 1             β˜…)
$noop(β˜…  ~/MusicRoot/Audio Books/Ready Player One                            β˜…)
$noop(β˜…  ~/MusicRoot/Podcasts/Mad Mad Music #29                              β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… - Alphabetize artist without leading "The"                           β˜…)
$noop(β˜… - Show Album Release Status on Album Directory                       β˜…)
$noop(β˜… - Show Record Label on Directory Name Directory                      β˜…)
$noop(β˜… - Show Catalogue Number in Album Directory Name                      β˜…)
$noop(β˜… - Show Track Duration in Filename                                    β˜…)
$noop(β˜… - Filtered character for files & directory naming                    β˜…)
$noop(β˜… - Include media type in directory name [when its not CD]             β˜…)
$noop(β˜… - Multi-Disc SubDirectory per Disc in Album Directory                β˜…)
$noop(β˜… - Custom directory tag for multi-disc CD/Vinyl [CD1/Disc1 by default]β˜…)
$noop(β˜… - Put multi-CD release in same directory [names become 101/102/201..]β˜…)
$noop(β˜… - Vinyl can use musicbrainz style for track [A1/A2/B1...]            β˜…)
$noop(β˜… - File Type SubDirectory in Album Directory                          β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… - For Sort Directory Overrides: titlesort, artistsort, albumsort     β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… ** Optional Plugin Needed for Last.fm [for category trending]        β˜…)
$noop(β˜…   -> https://github.com/fdemmer/Picard-Last.fm.ng-Plugin             β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… - 'For Sort Only'                                                    β˜…)
$noop(β˜…   Do not format filename, optional limited [0m00s] [128 CBR]         β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… - DevMode:                                                           β˜…)
$noop(β˜…   Allows better simulation control of variables for debugging        β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜… Do Not Taunt The Happy Tagging Ball                                  β˜…)
$noop(β˜…																											 β˜…)
$noop(β˜…----------------------------------------------------------------------β˜…)
$noop(β˜…   Based on the MBP Magic Script  By Ski-lleR                         β˜…)
$noop(β˜…   Thanks to avibrazil for his filter                                 β˜…)
$noop(β˜… > https://github.com/avibrazil/picard-scripting                      β˜…)
$noop(β˜…----------------------------------------------------------------------β˜…)
$noop(β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…β˜…)
$noop(β˜… INSERT COIN β˜…)

tdiaz,

This has been a great script. I’m a first time user to musicBrainz trying to organize a library of 15000 mp3s collected over 20 years. Thanks for all the 1/0 toggle features.

One question, is there a way I can make the podcasts and audiobooks much simpler? It’s nice having music sorted by A, B, C, etc. However, my list of Audiobooks and Podcats is much smaller, so they don’t need that. For example, I have this: Audiobook\C\C\C. S. Lewis\The Chronicles of Narnia_ The Magician's Nephew [CD] [2007] [Tyndale House Publishers]\MP3\[Disc 1].

I would prefer just to cut out the C\C\C. S. Lewis and MP3\[Disc 1] I’ve gone through the script for 15 minutes, but just didn’t see if this script had an easy way to disable all that.

Hmm… There might be. I’m working on the computer/desk area at the moment … but once I’m done, I’ll look at it. I need to use the nice big monitor…

I should say there is a way, but … I need to see just how massively β€œugly” it’s might be. :slight_smile: Though the more I think about it, I think maybe not so bad.

I wonder if I’m going to cause a Script Core Meltdown with this thing if I keep cramming more stuff in there… it’s already too big for a single post here.

MP3\ can be disabled, that is sort by extension. Like wise, I think [Disc x] (IIRC, %disctitle%) has a toggle too.

I agree about it getting bloated. :slight_smile: I was impressed someone worked this hard on an organizer already. The script can’t scale forever.

I was thinking an easier way may be just to do in a 2 parter. First run your script to put them all into various directories. Then restart MusicBrainz, and only load in the he Audiobooks and Podcasts directories, then reprocess those files using an easier script? It’s a bit cumbersome, but may be easier than trying to make one script do everything.

… but until that doesn’t work, it’s less work this way :sunglasses:

It kind of just … morphed. Hmm… I got it to do this … what about that, oh, hey, wait I can do this before that and … you should see the tagger script set for all this, and the macros and F-keys make it so much fun!

Point, Click, Select, Bam!

Ok, I’m trying to get a script to add the artist and featured artists if applicable to the file name that don’t currently contain them but I am as lost as can be trying to figure this out. Here is an example of what I mean.

Here’s what filename looks like currently: 01 - song name here.mp3

Here’s what I’m trying to get it to look like: 01 - artist name feat. artist - song name here.mp3

Now I know this probably isn’t that difficult but it seems to be beyond my capabilites.

This is actually pretty easy if you use the Additional Artists Variables plugin. That part of your file naming script would be something like:

$num(%tracknumber%,2) - %_artists_track_primary_cred%$if(%_artists_track_additional_cred%, feat. %_artists_track_additional_cred%,) - %title%
1 Like

@rdswift This didn’t seem to work for me. I tried inserting it in several places but it didn’t seem to change the output. I very well could be doing it wrong though as this is all new to me and there is a steep learning curve it seems. haha

Here is the code I’m currently using which is pretty much the default:

$if2(%albumartist%,%artist%)/
$if(%albumartist%,%album%/,)
$if($gt(%totaldiscs%,1),%discnumber%-,)$if($and(%albumartist%,%tracknumber%),$num(%tracknumber%,2) - ,)$if(%_multiartist%,%artist% - ,)%title% ```

Try the following:

$if2(%albumartist%,%artist%)/
$if(%albumartist%,%album%/,)
$if($gt(%totaldiscs%,1),%discnumber%-,)$if($and(%albumartist%,%tracknumber%),$num(%tracknumber%,2) - ,)%_artists_track_primary_cred%$if(%_artists_track_additional_cred%, feat. %_artists_track_additional_cred%,) - %title%

If that works, then you should be able to see where we made the changes.

1 Like

@rdswift This kind of worked. It got the correct formatting but didn’t insert the artist/s between the two -.

Output looks like: 01 - - song name.mp3

It sounds like you don’t have the Additional Artists Variables plugin installed and activated.

2 Likes

@rdswift Yep, your exactly right. I had that plugin installed but didn’t activate it as I thought it activated automatically. My bad. haha This is working now so thanks a bunch. I honestly would have never figured that out.

5 posts were split to a new topic: Help getting started with scripting

6 posts were merged into an existing topic: Help with refining picard script as well as how to sort radio and dj sets