non-relative playlist without drive letter?

Is there a way to write absolute playlists,
not relative to the work directory,
but without the drive letter?
My USB player may show up as any drive.
I'd like each playlist to work from anywhere on that drive.
My desired formatting looks like this, with no leading "." or drive letter.

\tunes\TWINPEAKS\Angelo Badalamenti - Twin Peaks Theme.mp3
\tunes\TWINPEAKS\Angelo Badalamenti - Laura Palmer's Theme.mp3
\tunes\TWINPEAKS\Angelo Badalamenti - Audrey's Dance.mp3
\tunes\TWINPEAKS\Angelo Badalamenti - The Nightingale.mp3

You may try something like this, adapt it to your needs:


Maybe you should add the missing bit of information, that this format string can be used within the Export function.

Kind regards,

Thank you , gentlemen. I'll give that a shot.

You can try this one $filename(m3u)#EXTM3U

$loop(%track%)#EXTINF:%_length_seconds%,%artist% - %title%

Intreresting... line line 3, what's the purpose of the \ before the : ?

chrisjj, I think it is not forbidden to escape any literal character used in a regular expression, so I did escape the semicolon for sure too.


Aha - I just thought I might have missed a requirement. And though : -> undefined behaviour, I agree it seems safe.

BTW, I think most concise is: $regexp(%_folderpath%,^.:,)%_filename_ext%

EDIT: " though : -> undefined behaviour " is incorrect:

above which : is not listed

Since Mp3tag v2.47 [2010-11-19]: $cutLeft(%_path%,2)


Note: on a UNC name, that gives an illegal path. At the pointer here:

Whereas the original does nothing.

One solution is $regexp(%_path%,'^\u:|^\\[^\\]+',) :