How to setup MCEBuddy on PlexDVR

Guide from Wiidesire:

https://www.reddit.com/r/PleX/comments/52v7vd/guide_commercialfree_experience_with_plex_dvr/

Video guide from Lon:

I have the Plex DVR set up and it seems to always add the (year) to the title. My SickRage doesn’t reliably match the shows when the year is in the name so I was wondering if anyone has a workaround for this (other than chaining filebot script to MCEbuddy)?

I have tried using MCEbuddy to separate it out, but since the year is part of the title coming in, it doesn’t remove.

Anyone know of a hidden option in Plex DVR to format its output naming? All my shows in Plex are without (year) so pushing them right into Plex creates an additional show folder instead of adding to the existing folder.

I wish I did. I posted to Plex and they say it somebody else’s problem. I am ready to go back to nPVR. Plex DVR is great except for their untested addition of the year in the title.

FYI MCEBuddy now includes a version with hardware acceleration of Comskip out of the box .

I know this is from a long time ago, but in case anyone is still looking for a solution, I ended up using a regex in the metadata correction options in MCEBuddy to resolve this. I’m not that good at regex, but this pattern seems to match and strip out the year if there is one.

Original Title: regex:([\w\s]+) \(\d\d\d\d\)
Corrected Title: regex:$1
1 Like

To quote @firefox15, “I know this is from a long time ago,” I have finally installed my WinTV quad tuner card, have it setup and recording everything fine, but I don’t understand how to setup, enable, or where to put in the regex info you mention above. I have the Donated version of MCEbuddy 2.4.11. Can you (or anyone else) give me pointers on where to do this? Thanks

Hi! Are you looking to do the same thing with RegEx? The good news is I have gotten much better with RegEx since I’ve had to use it in PowerShell, so I should be able to help you write an expression. What are you trying to do?

Anyway, you enter it in the conversion task -> advanced settings dropdown -> expert settings -> media information management -> correction. In my case, the original title is regex:([\w\s]+) \(\d\d\d\d\) and the corrected title is regex:$1. If you are looking to do the same thing, (.+) \(\d{4}\) is probably a cleaner RegEx.

1 Like

@firefox15
I added your regex:([\w\s]+) (\d\d\d\d) and regex:$1 but when it converted the file… it added “regex” to the front of the folder and filename.

Example:
Judge Judy - S01E01.mp4
was renamed to …
regexJudge Judy - S01E01.mp4

So I must be implementing regex incorrectly. My tuner records the shows and names them:
Judge Judy (1996) - S24E01 - 09-09-2019.ts

I want to convert them to MP4, but rename them without the “year” and “date recorded”. So like this…
Judge Judy - S24E01.mp4

I’d really like to add the episode name as well, but I think that’s beyond MCEbuddy and something I can add manually. Plex already displays the episode names it pulls from tvdb based on the SxxExx numbers, it just doesn’t rename the actual MP4 filename. Or at least to my knowledge.

So that’s what I’m trying to do. Here’s a screenshot of what I have based on your instructions…

Do you have the option enabled to rename by video information?

@firefox15
If you mean this… then yes…

Hmm, might have to check the logs to see what is going on. All I can say is that the RegEx is in the correct format. Once it starts getting into MCEBuddy, I’m less of an expert.

As far as I know, the RegEx portion is supposed to correct the lookup so that it can match with IMDB. Then if you have that checkbox checked, it should create it in the folder structure after the conversion without the year since IMDB doesn’t present the year.

@firefox15
So it seems like it’s partially working. One of the files I said had “regex” added to it seems to be an anomaly in that it didn’t have an SxxExx since it was a 1 episode only thing. All the others are converting and renaming ok. The year has been stripped but the date recorded is still being added.

So for instance, Judge Judy is renaming to: Judge Judy-S24E01-09 09 2019.mp4

I know these episode have actual names like: Dog bites kid or Rental nightmare

I checked other shows like Family Feud and it also is doing the same thing. Year is stripped but date recorded is getting appended with no actual episode name.

So your regex instructions were good… it’s just a matter of tweaking them now.

So, the RegEx portion is just for looking up information in TVDB. The point is so that the show information can be detected, then MCEBuddy can either use a pre-filled variable path (when you hover over "rename and sort . . . " you can see what this is), or you can write a rename rule yourself with the option below that.

I suspect that it might not be matching correctly with the online media information, but you would need to check the logs for that specific file to see. It should appear with the “log” button in the upper right of the app.

I looked into this a bit more because I was starting to experience it myself. Here is what is going on:

Plex recently changed their EPG source away from Gracenote to something much more inferior (Rovi, I think?). With this change, many more shows are missing S##E## information as the guide just does not have it available. When that happens, Plex will name the file something like ShowName-AirDate-Title instead of ShowName-S##E##-Title.

For whatever reason, the Regex engine in MCEBuddy is breaking when it detects the first format. Not only does the Regex not work (even though it should), but it prepends regex to the title, and basically it all just takes a huge dump. I have no idea why this happens (I suspect a bug in the application), and I submitted a bug report, but unfortunately no one has responded, and I have no idea if they ever will.

I decided to take matters into my own hands and write a PowerShell script to monitor my MCE folder for files that matched a Regex pattern, then I’m renaming them before MCEBuddy detects they are there so that MCEBuddy’s native metadata matching works again. If you are interested in this script or instructions, let me know.

My hope is that the application is corrected in a future release so that this is no longer necessary, but for now, it’s the best solution I have been able to come up with.

I am interested @firefox15.

I’m haply to dig up the script and post it for you, but it should be less necessary now that MCEBuddy has improved the Metadata matching logic. Are you still having an issue?

Yes I am having issues with my Wrestling Shows getting renamed.

I ended up using this:

$watcher = New-Object System.IO.FileSystemWatcher
$watcher.IncludeSubdirectories = $true
$watcher.Path = 'D:\ServerFolders\MCE Pickup\'
$watcher.EnableRaisingEvents = $true

$action =
{
    $path = $event.SourceEventArgs.FullPath
    $changetype = $event.SourceEventArgs.ChangeType

    $item = Get-Item $path
    $pattern = '^(.*) \(\d{4}\).*(\d{4}-\d{2}-\d{2}) \d{2} \d{2} \d{2} - (.*)$'

    if ($item.BaseName -match $pattern ) {
        Rename-Item -Path $item.FullName `
            -NewName "$($Matches[1]) - $($Matches[2]) - $($Matches[3])$($item.extension)"
    }
}

Register-ObjectEvent $watcher 'Created' -Action $action
Register-ObjectEvent $watcher 'Changed' -Action $action
Register-ObjectEvent $watcher 'Renamed' -Action $action
1 Like