Add Artist initials to Filename

Hi,

I'm new here and hope that someone can help me with me question.

I am wanting to change the Filename for live concert recordings in FLAC to the standard way these are presented, which is:

JAMC 20220417 01. Song Name 1.flac

where:

JAMC = initials for Jesus And Mary Chain (or whatever group)
20220417 = Year (date) without dashes
01. = Track
Song Name 1 = Title

I am able to get all bits, except for the initials for the artist, in an Action. Here is what I have done:

Format value
Field: _FILENAME
Format string: %artist% $replace(%year%,-,) $num(%track%,2). %title%

Obviously I need to "just" extract the initial for %artist%. I have tried various things but haven't worked out how to do this.

It would be great to get some help with this, if possible, please.

You could try:
$regexp(%artist%,'\W|^\W*(\b\w+\b)\W*$|\b(\w{1})\w+\b|\b(\w{1})\w*?\b',$1$2$3)

1 Like

Wow, that appears to work. That is a rather complicated looking expression. Thanks so much for this.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.