diff --git a/VERSION b/VERSION index c5a29148..c807441c 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.16.2-develop48 +1.16.3 diff --git a/docs/conf.py b/docs/conf.py index 7c392ffa..8bdf7fb4 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -130,6 +130,7 @@ html_theme_options = { ("_divider", ), ("Scheduling Guide", "home/guides/scheduling"), ("Image Asset Directory Guide", "home/guides/assets"), + ("Formula 1 Metadata Guide", "home/guides/formula"), ("_divider", ), ("Discord Server", "https://discord.gg/NfH6mGFuAB", True), ("Sponsor", "https://github.com/sponsors/meisnate12", True), diff --git a/docs/config/trakt.md b/docs/config/trakt.md index 1f635dbc..05d912de 100644 --- a/docs/config/trakt.md +++ b/docs/config/trakt.md @@ -33,7 +33,9 @@ trakt: 3. Enter `urn:ietf:wg:oauth:2.0:oob` for `Redirect uri`. 4. Click the `SAVE APP` button. 5. Record the `Client ID` and `Client Secret` as `client_id` and `client_secret` in your Configuration File. -6. Navigate to `https://trakt.tv/oauth/authorize?response_type=code&redirect_uri=urn:ietf:wg:oauth:2.0:oob&client_id=<>` replacing `<>` with your Client ID. -7. Record the `PIN` as `pin` in your Configuration File. +6. Click the Green Authorize Button next to the Redirect URI + + ![Trakt Authorize](trakt.png) +8. Record the `PIN` as `pin` in your Configuration File. * Run the script shortly after obtaining your pin I don't know if it expires at any point or not. \ No newline at end of file diff --git a/docs/config/trakt.png b/docs/config/trakt.png new file mode 100644 index 00000000..6fc6bf60 Binary files /dev/null and b/docs/config/trakt.png differ diff --git a/docs/home/guides/formula.md b/docs/home/guides/formula.md index 1e042e54..1d965a14 100644 --- a/docs/home/guides/formula.md +++ b/docs/home/guides/formula.md @@ -1,2 +1,67 @@ # Formula 1 Metadata Guide +This is a guide for setting up Formula 1 in Plex using the `f1_season` metadata attribute. + +Most of this guide is taken from a reddit [post](https://www.reddit.com/r/PleX/comments/tdzp8x/formula_1_library_with_automatic_metadata/) written by /u/Toastjuh. + +## Folder structure + +Let's start with the basics: + +* Every Formula 1 season will be a TV Show in Plex. Season 2001, Season 2002, etc. +* Every race will be a Season in Plex. Season 1 will be the Australian GP, Season 2 will be the Bahrain GP etc. +* Every session will be an Episode in Plex. Episode 1 will be Free Practice 1, Episode 2 will be Free Practice 2 etc. + +The folder format is like this: +``` +Formula -> Library Folder +├── Season 2018 -> Folder for each F1 Season +│ ├── 01 - Australian GP -> Folder for each Race in a season +│ ├── 01x10 - Australian GP - Highlights.mkv +│ ├── 01x01 - Australian GP - Free Practice 1.mkv +│ ├── 01x02 - Australian GP - Free Practice 2.mkv +│ ├── 01x03 - Australian GP - Free Practice 3.mkv +│ ├── 01x04 - Australian GP - Pre-Qualifying Buildup.mkv +│ ├── 01x05 - Australian GP - Qualifying Session.mkv +│ ├── 01x06 - Australian GP - Post-Qualyfing Analysis.mkv +│ ├── 01x07 - Australian GP - Pre-Race Buildup.mkv +│ ├── 01x08 - Australian GP - Race Session.mkv +│ ├── 01x09 - Australian GP - Post-Race Analysis.mkv +│ ├── 01x10 - Australian GP - Highlights.mkv +│ ├── 02 - Bahrein GP +│ ├── 01x10 - Bahrein GP - Highlights.mkv +│ ├── 01x01 - Bahrein GP - Free Practice 1.mkv +│ ├── 01x02 - Bahrein GP - Free Practice 2.mkv +│ ├── 01x03 - Bahrein GP - Free Practice 3.mkv +│ ├── 01x04 - Bahrein GP - Pre-Qualifying Buildup.mkv +│ ├── 01x05 - Bahrein GP - Qualifying Session.mkv +│ ├── 01x06 - Bahrein GP - Post-Qualyfing Analysis.mkv +│ ├── 01x07 - Bahrein GP - Pre-Race Buildup.mkv +│ ├── 01x08 - Bahrein GP - Race Session.mkv +│ ├── 01x09 - Bahrein GP - Post-Race Analysis.mkv +│ ├── 01x10 - Bahrein GP - Highlights.mkv +``` + +What matters for plex and for pmm. +* The show name can be whatever you want it to be but the pre created metadata file will only work if you use just the year numbers. +* The season folder can be called whatever you want as long as plex scans it in with the Season Number matching the race number. +* The episodes must follow plex's naming convention to have them scanned in properly but in order for PMM to update the metadata the files need to be specifically name like above. + +## Metadata File + +```yaml +metadata: + Season 2021: + f1_season: 2021 + round_prefix: true + Season 2020: + f1_season: 2020 + round_prefix: true +``` + +* Add `round_prefix: true` to have the race number appended to the beginning of the Race Name. +* Add `shorten_gp: true` to shorten `Grand Prix` to `GP` in all titles. + +Add an entry for every season you want to set the metadata for. The name needs to correspond with the name the season has in Plex! + +The posters of races you can get from https://www.eventartworks.de/ diff --git a/docs/metadata/metadata/show.md b/docs/metadata/metadata/show.md index b7c89284..14b7e8ea 100644 --- a/docs/metadata/metadata/show.md +++ b/docs/metadata/metadata/show.md @@ -86,7 +86,7 @@ The available attributes for editing shows, seasons, and episodes are as follows | `year` | Year of show for better identification | ✅ | ❌ | ❌ | | `tmdb_show` | TMDb Show ID to use for metadata useful for miniseries that have been compiled into a movie | ✅ | ❌ | ❌ | | `tmdb_movie` | TMDb Movie ID to use for metadata useful for movies that have been split into segments | ✅ | ❌ | ❌ | -| `f1_season` | F1 Season Year to make the Show represent a Season of F1 Races | ✅ | ❌ | ❌ | +| `f1_season` | F1 Season Year to make the Show represent a Season of F1 Races. See [Formula 1 Metadata Guide](../../home/guides/formula) for more information. | ✅ | ❌ | ❌ | | `round_prefix` | Used only with `f1_season` to add the round as a prefix to the Season (Race) Titles i.e. `Australian Grand Prix` --> `01 - Australian Grand Prix` | ✅ | ❌ | ❌ | | `shorten_gp` | Used only with `f1_season` to shorten `Grand Prix` to `GP` in the Season (Race) Titles i.e. `Australian Grand Prix` --> `Australian GP` | ✅ | ❌ | ❌ | | `seasons` | Mapping to define Seasons | ✅ | ❌ | ❌ | diff --git a/plex_meta_manager.py b/plex_meta_manager.py index 77ae0116..ae03672f 100644 --- a/plex_meta_manager.py +++ b/plex_meta_manager.py @@ -940,7 +940,7 @@ def run_collection(config, library, metadata, requested_collections): library.status[mapping_name]["sonarr"] += sonarr_add valid = True - if builder.build_collection and ( + if builder.build_collection and not builder.blank_collection and ( (builder.smart_url and len(library.get_filter_items(builder.smart_url)) < builder.minimum) or (not builder.smart_url and len(builder.added_items) + builder.beginning_count < builder.minimum) ):