Move non-CLI specific code from Trash project to TrashLib. This is for
future code sharing with Recyclarr. Trash project is officially
deprecated and will eventually go away in favor of the web app.
A new setting under `quality_profiles` of the custom format listing
named `reset_unmatched_scores` that allows the user to specify if
unmapped scores (those CFs not specified in config) should be reset to 0
during quality profile updates.
Fixes#10.
Trash has started putting scores in the actual importable JSON data. If
a score is found in the JSON data, that takes precedence over any score
parsed from the guide markdown. The `trash_score` field is not required
for backward compatibility.
There was an ambiguity with one custom format named 'DoVi'. This one had
two custom formats in the guide. The intent was for the user to choose
only one of these, but the name was kept identical so that name appeared
in the filename for media when it was renamed.
This allows the user to choose which of those two they want using the
`trash_id` property.
Add a version number field to the custom format cache object. This is an
attempt at future-proofing the cache in case I ever need to update the
schema in a non-backward compatible way.
- Synchronize custom formats to Radarr
- Quality profiles can be assigned scores from the guide
- Deletion support for custom formats removed from config or the guide.
- Caching system for keeping track of Custom Format IDs and Trash IDs to
better support renames, deletions, and other stateful behavior.
Also added some code sharing between Radarr and Sonarr for this stuff,
since they are largely similar (Radarr has preferred size but the rest
is the same).