Help with script please :)

Tags: #<Tag:0x00007f4d62368010> #<Tag:0x00007f4d62393f58>

I’ve been at it all day but I just can’t get it to work…
I want my file naming script to rename my files to:

/Volumes/External HDD/Artist/Album/Artist - Title (… bpm).mp3

Can somebody help me with the script that does this for me?

It’s quite simple when you know the way it works!

Links to the documentation: %tag%, $function().

Here’s how I accomplished your naming scheme. Just replace the “C:\MyMusic” in the destination directory field with your own base path.

You may want to add %tracknumber% somewhere there. Or even $num(%tracknumber%,2) for padding the small numbers with zeros.

$if(%bpm%, \(%bpm% bpm\))

Here’s the same in an image form. This example sets some constants so the script becomes more readable. (Learnt this from the tagger script thread.)


@phonebox Where do you use %_null%, %_leftbracket%, %_rightbracket% and %_comma%?

In the above script, I don’t use them at all. I copied the constants from my main tagging script where I have used them when I have wanted to signify that a character will be visible in the end results and it’s not just part of the code.

%_null% is used in place of an empty argument in a function. I think it makes the script more readable. :thinking: