Skip to content

Latest commit

 

History

History
99 lines (81 loc) · 3.19 KB

best_quality.md

File metadata and controls

99 lines (81 loc) · 3.19 KB
title description published date tags editor dateCreated
best_quality
true
2024-04-02 16:50:36 UTC
markdown
2022-09-18 05:02:29 UTC

Best Quality

The best_qality plugin will sort entries, grouped by an identifier, and allow action on the best quality and lower qualities.

Settings

Option Default Description
identified_by auto Define how entries are identified to be a same content, default value auto uses entry media_id field. Supports Jinja Template.
on_best do_nothing The action to preform on which has the best quality. Value do_nothing won't act on the entry (undecided) but allow it to by handled by other plugins.
on_lower reject The action to preform on entries which are lower then the best quality. Value do_nothing won't act on the entry (undecided) but allows it to by handled by other plugins.
single_best yes Consider only the first one as the best entry.

Syntax:

best_quality:
  identified_by: <jinja template>
  on_best: [accept|reject|do_nothing]
  on_lower: [accept|reject|do_nothing]
  single_best: [yes|no]

Example

Let's assume the input has several of the same movie. The best_quality plugin will only allow the best quality.

tasks:
  high_rated_movies:
    best_quality:
      # Let imdb handle the accept
      on_best: do_nothing
      on_lower: reject
    imdb:
      min_score: 8.5
      min_votes: 5000

Example with custom identifier

The metainfo_series and metainfo_movie plugins will, by default, set an identifier.

You can override the format using Jinja Templates.

best_quality:
  identified_by: "{{ some_identifying_field }}"

Example with timeframe and upgrade

In this example the first task will download movies, waiting 1 day for 1080p. If 720p and 1080p of the same movie appears up in the feed at the same time best_quality will ensure only the best is accepted by imdb.

The second task will upgrade the movie in future for 1 week.

tasks:
  great_movies:
    # any input works, using rss as an example
    rss: https://example.com/feed.xml
    upgrade:
      # We must add this so the upgrade plugin can track the downloaded qualities
      tracking: yes
    timeframe:
      wait: 1 day
      # Let imdb handle the accept
      on_reached: do_nothing
      target: 1080p
    # If input has same movie twice, ensure only best get's through.
    best_quality:
      on_best: do_nothing
      on_lower: reject
    imdb:
      min_score: 7.5
      min_votes: 5000
    # any output works, using download as an example
    download: ~/watchfolder/

  upgrade_movies:
    # any input works, using rss as an example
    rss: https://example.com/feed.xml
    upgrade:
      timeframe: 1 week
      target: 1080p
      propers: yes
    # any output works, using download as an example
    download: ~/watchfolder/