pano-scrobbler icon indicating copy to clipboard operation
pano-scrobbler copied to clipboard

Regex across multiple fields

Open djryan opened this issue 3 years ago • 1 comments

Loving the pattern edits!

In Podcast Addict, podcasts with chapters appear as:

$TITLE - Chapter text $ARTIST - Podcast Name $TRACK - $Episode-Title ($Artist Name)

I've got a regex to pull out Episode Name as $1 and Artist Name as $2, but can only make the change in a single field. Is it possible to read one field and edit another?

djryan avatar Jul 21 '21 12:07 djryan

I'm a Podcast Addict user also and the incorrect mapping is annoying. I can't seem to figure out the pattern edits though. How do replace $Artist with Artist name?

pedrojvaz avatar Sep 10 '21 11:09 pedrojvaz

The same issue with RadioTunes app (former Sky.fm) Metadata parsed incorrectly as follows: TRACK - always set to radio station name, Smooth Jazz or something else ARTIST - (Artist name) - (Track title) ALBUM - (Track title)

ARTIST field could be corrected with regex, but others are not. We need to be able to write regex capture groups into another fields.

Goonik avatar Apr 10 '23 10:04 Goonik

I'm thinking of adding an extract mode. The user will be presented with 4 edit boxes, for the existing track, album, artist and album artist fields. They will need to use capture groups named exactly as track, album, artist or albumArtist to extract those fields from other fields. The user will also be able to limit a pattern edit to certain apps.

For the radiotunes example above, the user would need: An extract rule:

TRACK - (blank) ALBUM - (blank) ARTIST - (?<artist>.+) - (?<track>.+) ALBUM ARTIST - (blank) Limit to: Radiotunes Continue matching, if found: true

And another normal regex edit:

Pattern: .+ Fields: album Replacement: (blank) Limit to: Radiotunes

kawaiiDango avatar May 30 '23 12:05 kawaiiDango

Has this feature been implemented? Maybe I'm missing it, I'm confused about the closure.

forenta avatar Feb 23 '24 11:02 forenta

The extract mode has been implemented, yes.

kawaiiDango avatar Feb 23 '24 14:02 kawaiiDango