Hi Plex Dev type people!,
As I've had many an occasion to perform mass updates on my Library, or to scriptomaticaly handle the files it contains on the basis of library metadata as opposed to file path, I thought I'd start a mini-project, PoSH4PlexAp:
It's pretty embryonic at the moment, but the functions contained in the PowerShell script allow you to:
Get-PlexVideo ### Queries the library of the Plex Media Server (PMS) specified for videos, returning metadata attributes. Supports filtering on the basis of 'viewed' status, video type (TV, Movies, All), series number, episode number, video name and/or show name
Get PlexShow ### Queries the TV sections of the PMS library for TV shows, returning metadata attributes. Supports filtering on the basis of show name and/or 'viewed' status
Set-PlexViewedStatus ### Sets the viewed status (watched/unwatched) of videos, series and shows in the PMS library. Accepts user-typed unique ID (ratingKey) of object from Plex library or pipe-lined input from the above two functions
I also plan to develop the following functions:
Get-PlexSeries ### Query library of the PMS for TV series
Set-PlexVideo ### Update metadata attributes on Plex video objects
Set-PlexShow ### Update metadata attributes on Plex show objects
Set-PlexSeries ### Update metadata attributes on Plex series objects
Truthfully though, I want to spend the next few nights tidying up the code a little, enhancing the comments and making the current 'Get' functions support pipeline input, so the extra functions could take a few days/weeks.
I'd really appreciate anyone who is up for beta testing this going to the CodePlex site, trying out the script and of course feeding back to me.
If you can read my code (as in, it's not too messy - I'm not a Dev by trade) I'd be really interested in your thoughts/analysis.