mirror of
https://github.com/StuffAnThings/qbit_manage.git
synced 2025-10-29 15:36:33 +08:00
Adds ignoreTags_OnUpdate in config settings #95
[FR]: Tag Torrents with Existing Tags #95
This commit is contained in:
parent
102a1e083b
commit
8907abbf45
3 changed files with 13 additions and 6 deletions
|
|
@ -12,7 +12,10 @@ qbt:
|
||||||
settings:
|
settings:
|
||||||
force_auto_tmm: False # Will force qBittorrent to enable Automatic Torrent Management for each torrent.
|
force_auto_tmm: False # Will force qBittorrent to enable Automatic Torrent Management for each torrent.
|
||||||
tracker_error_tag: issue # Will set the tag of any torrents that do not have a working tracker.
|
tracker_error_tag: issue # Will set the tag of any torrents that do not have a working tracker.
|
||||||
|
ignoreTags_OnUpdate: # Will ignore a list of tags when running the update tag function
|
||||||
|
- noHL
|
||||||
|
- issue
|
||||||
|
- cross-seed
|
||||||
directory:
|
directory:
|
||||||
# Do not remove these
|
# Do not remove these
|
||||||
# Cross-seed var: </your/path/here/> # Output directory of cross-seed
|
# Cross-seed var: </your/path/here/> # Output directory of cross-seed
|
||||||
|
|
@ -37,7 +40,7 @@ cat:
|
||||||
# Tag Parameters
|
# Tag Parameters
|
||||||
tracker:
|
tracker:
|
||||||
# <Tracker URL Keyword>: # <MANDATORY> This is the keyword in the tracker url
|
# <Tracker URL Keyword>: # <MANDATORY> This is the keyword in the tracker url
|
||||||
# <MANDATORY> Set tag name
|
# <MANDATORY> Set tag name. Can be a list of tags or a single tag
|
||||||
# tag: <Tag Name>
|
# tag: <Tag Name>
|
||||||
# <OPTIONAL> Will set the torrent Maximum share ratio until torrent is stopped from seeding/uploading. -2 means the global limit should be used, -1 means no limit.
|
# <OPTIONAL> Will set the torrent Maximum share ratio until torrent is stopped from seeding/uploading. -2 means the global limit should be used, -1 means no limit.
|
||||||
# max_ratio: 5.0
|
# max_ratio: 5.0
|
||||||
|
|
@ -51,13 +54,16 @@ tracker:
|
||||||
tag: AnimeBytes
|
tag: AnimeBytes
|
||||||
notifiarr: animebytes
|
notifiarr: animebytes
|
||||||
avistaz:
|
avistaz:
|
||||||
tag: Avistaz
|
tag:
|
||||||
|
- Avistaz
|
||||||
|
- tag2
|
||||||
|
- tag3
|
||||||
max_ratio: 5.0
|
max_ratio: 5.0
|
||||||
max_seeding_time: 129600
|
max_seeding_time: 129600
|
||||||
limit_upload_speed: 150
|
limit_upload_speed: 150
|
||||||
notifiarr: avistaz
|
notifiarr: avistaz
|
||||||
beyond-hd:
|
beyond-hd:
|
||||||
tag: Beyond-HD
|
tag: [Beyond-HD, tag2, tag3]
|
||||||
notifiarr: beyondhd
|
notifiarr: beyondhd
|
||||||
blutopia:
|
blutopia:
|
||||||
tag: Blutopia
|
tag: Blutopia
|
||||||
|
|
|
||||||
|
|
@ -81,6 +81,8 @@ class Config:
|
||||||
"force_auto_tmm": self.util.check_for_attribute(self.data, "force_auto_tmm", parent="settings", var_type="bool", default=False),
|
"force_auto_tmm": self.util.check_for_attribute(self.data, "force_auto_tmm", parent="settings", var_type="bool", default=False),
|
||||||
"tracker_error_tag": self.util.check_for_attribute(self.data, "tracker_error_tag", parent="settings", default='issue')
|
"tracker_error_tag": self.util.check_for_attribute(self.data, "tracker_error_tag", parent="settings", default='issue')
|
||||||
}
|
}
|
||||||
|
default_ignore_tags = ['noHL', self.settings["tracker_error_tag"], 'cross-seed']
|
||||||
|
self.settings["ignoreTags_OnUpdate"] = self.util.check_for_attribute(self.data, "ignoreTags_OnUpdate", parent="settings", default=default_ignore_tags, var_type="list")
|
||||||
|
|
||||||
default_function = {
|
default_function = {
|
||||||
'cross_seed': None,
|
'cross_seed': None,
|
||||||
|
|
|
||||||
|
|
@ -193,8 +193,7 @@ class Qbt:
|
||||||
dry_run = self.config.args['dry_run']
|
dry_run = self.config.args['dry_run']
|
||||||
loglevel = 'DRYRUN' if dry_run else 'INFO'
|
loglevel = 'DRYRUN' if dry_run else 'INFO'
|
||||||
num_tags = 0
|
num_tags = 0
|
||||||
tag_error = self.config.settings['tracker_error_tag']
|
ignore_tags = self.config.settings['ignoreTags_OnUpdate']
|
||||||
ignore_tags = ['noHL', tag_error, 'cross-seed']
|
|
||||||
if self.config.args['tag_update']:
|
if self.config.args['tag_update']:
|
||||||
separator("Updating Tags", space=False, border=False)
|
separator("Updating Tags", space=False, border=False)
|
||||||
for torrent in self.torrent_list:
|
for torrent in self.torrent_list:
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue