Merge branch 'master' into dependabot/pip/mkdocs-redirects-1.2.0

pull/833/head
TRaSH 2 years ago committed by GitHub
commit 8d784266be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -35,6 +35,28 @@
[[% filter indent(width=4) %]][[% include 'Downloaders/NZBGet/scripts/HashRenamer/HashRenamer.py' %]][[% endfilter %]]
```
## replace_for
??? info "Replaces underscores with dots"
- Title: `replace_for.py`
- Author: miker
Replaces underscores with dots in downloaded filename to prevent download loops with poorly named releases on some indexers (often HONE releases).
Install Instructions:
1. Copy script to NZBGet's script folder
1. run: `sudo chmod +x replace_for.py`
1. in SABnzbd go to `Settings` => `Extension Scripts`
1. Enable `replace_for.py` in the `Extensions` setting.
??? example "Script"
```python
[[% filter indent(width=4) %]][[% include 'Downloaders/NZBGet/scripts/replace_for/replace_for.py' %]][[% endfilter %]]
```
## WtFnZb-Renamer
??? info "Renames hashed media files to match the source NZB"

@ -0,0 +1,40 @@
#!/usr/bin/env python3
#
##############################################################################
### NZBGET POST-PROCESSING SCRIPT ###
# Replace underscore with dot.
#
# Author: miker
#
#
# Copy script to NZBGet's script folder.
# Run sudo chmod +x replace_for.py
#
#
# NOTE: This script requires Python to be installed on your system.
### NZBGET POST-PROCESSING SCRIPT ###
##############################################################################
from __future__ import print_function
import os, re, sys
# Exit codes used by NZBGet
POSTPROCESS_SUCCESS=93
POSTPROCESS_ERROR=94
POSTPROCESS_SKIP=95
directory = os.environ['NZBPP_DIRECTORY']
print('Directory used is: ',directory)
for path, currentDirectory, files in os.walk(directory):
for file in files:
if file.find("_") !=-1:
dst = file.replace('_', '.')
os.rename (os.path.join(path,file),os.path.join(path,dst) )
print('Result: ',file," renamed to ",dst)
sys.exit(POSTPROCESS_SUCCESS)

Binary file not shown.

After

Width:  |  Height:  |  Size: 102 KiB

@ -26,3 +26,27 @@
```python
[[% filter indent(width=4) %]][[% include 'Downloaders/SABnzbd/scripts/Clean/Clean.py' %]][[% endfilter %]]
```
## replace_for
??? info "Replaces underscores with dots"
- Title: `replace_for.py`
- Author: miker
Replaces underscores with dots in downloaded filename to prevent download loops with poorly named releases on some indexers (often HONE releases).
Install Instructions:
1. Copy script to sabnzbd's script folder
1. run: `sudo chmod +x replace_for.py`
1. in SABnzbd go to `Settings` => `Categories`
1. Change script for required categories and select: `replace_for.py`
![!Enable replace_for.py](/Downloaders/SABnzbd/images/sabnzbd-categories-replace_for.png)
??? example "Script"
```python
[[% filter indent(width=4) %]][[% include 'Downloaders/SABnzbd/scripts/replace_for/replace_for.py' %]][[% endfilter %]]
```

@ -0,0 +1,42 @@
#!/usr/bin/python3 -OO
##################################################################
### SABnzbd - Replace underscores with dots ##
##################################################################
## ##
## NOTE: This script requires Python 3 ##
## ##
## Author: miker ##
## ##
## Install: ##
## 1. Copy script to sabnzbd's script folder ##
## 2. run: sudo chmod +x replace_for.py ##
## 3. in SABnzbd go to Config > Categories ##
## 4. Assign replace_for.py to the required category ##
##################################################################
import sys
import os
import os.path
try:
(scriptname, directory, orgnzbname, jobname, reportnumber, category, group, postprocstatus, url) = sys.argv
except:
print("No commandline parameters found")
sys.exit(1) # exit with 1 causes SABnzbd to ignore the output of this script
files = os.listdir(directory)
for src in files:
if src.find("_") !=-1:
dst = src.replace('_', '.')
os.rename (os.path.join(directory,src),os.path.join(directory,dst) )
print(src, "renamed to ",dst)
print()
print()
print()
print()
# 0 means OK
sys.exit(0)

@ -19,7 +19,7 @@ This page will provide you with guidance on how to install several Docker images
??? example "Automated script (**:bangbang:Use this script at your own risk:bangbang:**) - [CLICK TO EXPAND]"
!!! Warning
Though, we offer a short way out. This is intended as a quick way to do everything that is written on this page within one script.
Though, we offer a short way out. This is intended as a quick way to do everything that is written on this page within one script. And is only for initial setup. After that, you need to manage it yourself. Rerunning the script will reset all personal changes made in the compose/env.
The script is only tested on Synology DSM7.1.

@ -56,7 +56,7 @@ I only do WEB-DL myself for TV shows because in my opinion WEB-DL is the sweet s
------
### Sonarr Quality Definitions - Anime (Work in Progress)
### Sonarr Quality Definitions - Anime
| Quality | Minimum | Maximum |
| ----------------------------------------------------------------- | ------------------------------------------------------------- | ------------------------------------------------------------- |
@ -74,6 +74,11 @@ I only do WEB-DL myself for TV shows because in my opinion WEB-DL is the sweet s
| {{ sonarr['quality-size']['anime']['qualities'][11]['quality'] }} | {{ sonarr['quality-size']['anime']['qualities'][11]['min'] }} | {{ sonarr['quality-size']['anime']['qualities'][11]['max'] }} |
| {{ sonarr['quality-size']['anime']['qualities'][12]['quality'] }} | {{ sonarr['quality-size']['anime']['qualities'][12]['min'] }} | {{ sonarr['quality-size']['anime']['qualities'][12]['max'] }} |
| {{ sonarr['quality-size']['anime']['qualities'][13]['quality'] }} | {{ sonarr['quality-size']['anime']['qualities'][13]['min'] }} | {{ sonarr['quality-size']['anime']['qualities'][13]['max'] }} |
| {{ sonarr['quality-size']['anime']['qualities'][14]['quality'] }} | {{ sonarr['quality-size']['anime']['qualities'][14]['min'] }} | {{ sonarr['quality-size']['anime']['qualities'][14]['max'] }} |
| {{ sonarr['quality-size']['anime']['qualities'][15]['quality'] }} | {{ sonarr['quality-size']['anime']['qualities'][15]['min'] }} | {{ sonarr['quality-size']['anime']['qualities'][15]['max'] }} |
| {{ sonarr['quality-size']['anime']['qualities'][16]['quality'] }} | {{ sonarr['quality-size']['anime']['qualities'][16]['min'] }} | {{ sonarr['quality-size']['anime']['qualities'][16]['max'] }} |
| {{ sonarr['quality-size']['anime']['qualities'][17]['quality'] }} | {{ sonarr['quality-size']['anime']['qualities'][17]['min'] }} | {{ sonarr['quality-size']['anime']['qualities'][17]['max'] }} |
| {{ sonarr['quality-size']['anime']['qualities'][18]['quality'] }} | {{ sonarr['quality-size']['anime']['qualities'][18]['min'] }} | {{ sonarr['quality-size']['anime']['qualities'][18]['max'] }} |
{! include-markdown "../../includes/support.md" !}
<!-- --8<-- "includes/support.md" -->
<!-- --8<-- "includes/support.md" -->

Binary file not shown.

After

Width:  |  Height:  |  Size: 134 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 71 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

@ -1,25 +1,32 @@
# How to setup Custom Formats (Anime)
!!! attention
You must be running Sonarr V4 to be able to use this setup
You must be running Sonarr V4 to be able to use this setup.
![V4](https://img.shields.io/badge/dynamic/json?query=%24.version&url=https://raw.githubusercontent.com/hotio/sonarr/v4/VERSION.json&label=Current%20V4%20Version&style=for-the-badge&color=4051B5)
![V4](https://img.shields.io/badge/dynamic/json?query=%24.version&url=https://raw.githubusercontent.com/hotio/sonarr/v4/VERSION.json&label=Current%20V4%20Version&style=for-the-badge&color=4051B5)
!!! note
This guide is created and maintained by [FonduemangVI](https://github.com/FonduemangVI) and [rg9400](https://github.com/rg9400)
It's recommended to run two Sonarr instances. One for Anime and one for normal TV shows, or you can make use of Quality Profiles and score different Custom Formats (CFs) as required.
It's recommended to run two Sonarr instances. One for Anime and one for normal TV shows, or you can make use of Quality Profiles and score different Custom Formats (CFs) as required.
The aim of this guide is to grab the best release overall (as per [SeaDex](https://sneedex.moe/){:target="_blank" rel="noopener noreferrer"}) and not necessarily just dual audio.
The vast majority of releases can be found on [Nyaa](https://nyaa.si/){:target="_blank" rel="noopener noreferrer"} or [AB](https://animebytes.tv/){:target="_blank" rel="noopener noreferrer"}
!!! note
!!! info ""
Nyaa is a public tracker while AB is an invite only tracker.
---
## Media Management
### Series Type
When adding a new series make sure you set the series type to Anime
??? check "example - [Click to Expand]"
![!cfa-seriestype](images/cfa-seriestype.png)
### Recommended naming scheme
```bash
@ -70,7 +77,9 @@ Result:
## Quality Settings
For quality settings please refer to [Sonarr Quality Definitions - Anime](/Sonarr/Sonarr-Quality-Settings-File-Size/#sonarr-quality-definitions-anime-work-in-progress){:target="_blank" rel="noopener noreferrer"}
For quality settings please refer to [Sonarr Quality Definitions - Anime](/Sonarr/Sonarr-Quality-Settings-File-Size/#sonarr-quality-definitions-anime){:target="_blank" rel="noopener noreferrer"}
If you are only running a single instance of Sonarr you can instead use [Sonarr Quality Definitions](/Sonarr/Sonarr-Quality-Settings-File-Size/#sonarr-quality-definitions){:target="_blank" rel="noopener noreferrer"}
---
@ -78,25 +87,18 @@ For quality settings please refer to [Sonarr Quality Definitions - Anime](/Sonar
We need to create a new profile called `Remux-1080p - Anime` due to the way anime can be named we will need to merge a few qualities together see [here](/Sonarr/Tips/Merge-quality/){:target="_blank" rel="noopener noreferrer"} for an example.
We need to add `Bluray-1080p Remux` and `Bluray-1080p` into a group together, and `HDTV-1080p` into the same group as `WEBDL-1080p` and `WEBRip-1080p` so that scoring will work correctly.
We need to add `Bluray-1080p Remux` and `Bluray-1080p` into a group together, `HDTV-1080p` into the same group as `WEBDL-1080p` and `WEBRip-1080p`, and lastly `HDTV-720p` into the same group as `WEBDL-720p` and `WEBRip-720p` so that the scoring will work correctly.
Go to `Settings` => `Profiles`
??? check "example - [Click to Expand]"
![!cf-settings-profiles](images/cfa-settings-profiles.png)
![!cf-settings-profiles](images/cfa-settings-profiles.png)
![!cfa-mergedqualities](images/cfa-mergedqualities.png)
We then need to select and organise qualities as below.
We then need to select and organise the qualities like below.
![!cfa-qualityorder](images/cfa-qualityorder.png)
Make sure `Upgrades Allowed` is ticked then set the `Upgrade Until` section to `Bluray-1080p` and the `Upgrade Until Custom Format Score` to `10000`
After this has been done your profile should look like below.
![!cfa-qualityprofile](images/cfa-qualityprofile.png)
---
## Anime CF/Scoring
@ -104,25 +106,65 @@ After this has been done your profile should look like below.
!!! note
We're going to make use of the below custom formats. See [How to import Custom Formats](/Sonarr/sonarr-import-custom-formats/){:target="_blank" rel="noopener noreferrer"} for how to import them.
### Default Scoring
{! include-markdown "../../includes/cf/sonarr-anime.md" !}
<!-- --8<-- "includes/cf/sonarr-anime.md" -->
The scoring that has been set is the recommended scoring, however some of the CFs are optional depending on what you prefer.
`Anime Dual Audio`, `Uncensored` and `10bit` can be given postive scores if you want to prefer content with these attributes.
`Anime Dual Audio`, `Uncensored` and `10bit` can be given positive scores if you want to prefer content with these attributes.
`Anime Raws` and `Dubs Only` are optional negative scores, if you prefer these attributes you can give them a positive score.
`Anime Raws` and `Dubs Only` are negatively scored, however if you prefer these attributes you can give them a positive score.
Once the custom formats have been imported you can set the scores as above. To do this go to `Settings` => `Profiles` and select the `Remux-1080p - Anime` profile that was setup before.
??? check "example - [Click to Expand]"
![!cf-settings-profiles](images/cfa-settings-profiles.png)
![!cf-settings-profiles](images/cfa-settings-profiles.png)
In the profile enter the scores as per the above table in this section.
![!cfa-scoring](images/cfa-scoring.png)
![!cfa-default-scoring](images/cfa-default-scoring.png)
After you are done it should look like the image above.
### Dual Audio Scoring
If you prefer `Dual Audio` releases you have a few options depending on your preference.
If you want to prefer `Dual Audio` within the same tier give the `CF` a score of `10`, if you want it to be preferred a tier above give the `CF` a score of `101`, and if you want to prefer it over any tiers give the `CF` a score of `2000`.
If you must have `Dual Audio` releases set the `Minimum Custom Format Score` to 2000 in the `Remux-1080p - Anime` profile that you setup earlier.
Using this scoring you will still benefit from the tiers if a better release group does a `Dual Audio` release.
Below is an example of the scoring set to prefer `Dual Audio` over any tier.
![!cfa-da-scoring](images/cfa-da-scoring.png)
### Uncensored Scoring
!!! note
Most BDs are uncensored by default, so most groups do not include that in the name.
If you prefer `Uncensored` releases you have a few options depending on your preference.
If you want to prefer `Uncensored` within the same tier give the `CF` a score of `10`, if you want it to be preferred a tier above give the `CF` a score of `101`.
Using this scoring you will still benefit from the tiers if a better release group does an `Uncensored` release.
Below is an example of the scoring set to prefer `Uncensored` a tier above.
![!cfa-uncensored-scoring](images/cfa-uncensored-scoring.png)
### Finishing up
Once you have set your preferred scoring you will need to make one more change to your `Remux-1080p - Anime` profile.
Make sure `Upgrades Allowed` is ticked then set the `Upgrade Until` section to `Bluray-1080p` and the `Upgrade Until Custom Format Score` to `10000`
After this has been done your profile should look like below. This is an example of the Default Scoring setup.
![!cfa-complete](images/cfa-complete.png)
### Acknowledgements
Most of my information and knowledge came from:
@ -136,4 +178,4 @@ Most of my information and knowledge came from:
- [TRaSH](https://trash-guides.info/) (For allowing me to utilize his website for our guide and general knowledge share.)
{! include-markdown "../../includes/support.md" !}
<!-- --8<-- "includes/support.md" -->
<!-- --8<-- "includes/support.md" -->

@ -2,87 +2,117 @@
"trash_id": "387e6278d8e06083d813358762e0ac63",
"type": "anime",
"qualities": [
{
"quality": "SDTV",
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "WEBRip-480p",
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "WEBDL-480p",
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "DVD",
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "Bluray-480p",
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "HDTV-720p",
"min": 2.3,
"preferred": 50.4,
"max": 51.4
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "HDTV-1080p",
"min": 2.3,
"preferred": 99,
"max": 100
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "WEBRip-720p",
"min": 4.3,
"preferred": 99,
"max": 100
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "WEBDL-720p",
"min": 4.3,
"preferred": 50.4,
"max": 51.4
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "Bluray-720p",
"min": 4.3,
"preferred": 101.2,
"max": 102.2
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "WEBRip-1080p",
"min": 4.5,
"preferred": 256.4,
"max": 257.4
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "WEBDL-1080p",
"min": 4.3,
"preferred": 252.6,
"max": 253.6
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "Bluray-1080p",
"min": 4.3,
"preferred": 257.1,
"max": 258.1
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "Bluray-1080p Remux",
"min": 0,
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "HDTV-2160p",
"min": 69.1,
"preferred": 349,
"max": 350
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "WEBRip-2160p",
"min": 69.1,
"preferred": 349,
"max": 350
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "WEBDL-2160p",
"min": 69.1,
"preferred": 349,
"max": 350
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "Bluray-2160p",
"min": 94.6,
"min": 5,
"preferred": 399,
"max": 400
},
{
"quality": "Bluray-2160p Remux",
"min": 204.4,
"min": 5,
"preferred": 399,
"max": 400
}

Loading…
Cancel
Save