Skip to content

Instantly share code, notes, and snippets.

@BenMcLean
Last active March 30, 2022 14:25
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BenMcLean/9eebf3b0489cbe16c25284a00e563c66 to your computer and use it in GitHub Desktop.
Save BenMcLean/9eebf3b0489cbe16c25284a00e563c66 to your computer and use it in GitHub Desktop.
$set(_year,$left($if2(%originaldate%,%date%),4))
$if(_year,%_year% )
%album%
$if($and(%releasetype%,$not($find(%releasetype%,album))), \(%releasetype%\))
($if2(%albumartist%,%artist%))
$if($eq($upper(%_extension%),MP3),, $upper(%_extension%))
/
$if($gt(%totaldiscs%,1),$if(%discsubtitle%,CD$num(%discnumber%,$len(%totaldiscs%)) %discsubtitle%/)$num(%discnumber%,$len(%totaldiscs%))-,)
$num(%tracknumber%,$if($gt($len(%totaltracks%),2),$len(%totaltracks%),2)) %title%
$if($find(%albumartist%,Various), \(%artist%\))
$if2(%artist%,%albumartist%) - %title%
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment