From 98c4b1d2d7104a9cc8f6a1f4f5f60a7513d1de2d Mon Sep 17 00:00:00 2001 From: Garfield69 Date: Fri, 18 Sep 2020 12:54:40 +1200 Subject: [PATCH] sharewood: add config multi option. #9544 #9456 add freeleech filter add minimumratio and minimumseedtime --- src/Jackett.Common/Definitions/sharewood.yml | 47 +++++++++++++++++++- 1 file changed, 46 insertions(+), 1 deletion(-) diff --git a/src/Jackett.Common/Definitions/sharewood.yml b/src/Jackett.Common/Definitions/sharewood.yml index 766d767ab..96a6482e7 100644 --- a/src/Jackett.Common/Definitions/sharewood.yml +++ b/src/Jackett.Common/Definitions/sharewood.yml @@ -60,6 +60,29 @@ settings: - name: password type: password label: Password + - name: freeleech + type: checkbox + label: Search freeleech only + default: false + - name: multilang + type: checkbox + label: Replace MULTI by another language in release name + default: false + - name: multilanguage + type: select + label: Replace MULTI by this language + default: FRENCH + options: + FRENCH: "FRENCH" + MULTI.FRENCH: "MULTI.FRENCH" + ENGLISH: "ENGLISH" + MULTI.ENGLISH: "MULTI.ENGLISH" + VOSTFR: "VOSTFR" + MULTI.VOSTFR: "MULTI.VOSTFR" + - name: vostfr + type: checkbox + label: Replace VOSTFR with ENGLISH + default: false - name: sort type: select label: Sort requested from site @@ -113,6 +136,7 @@ search: sorting: "{{ .Config.sort }}" direction: "{{ .Config.type }}" qty: 100 + freeleech: "{{ if .Config.freeleech }}1{{ else }}{{ end }}" rows: selector: div.table-responsive-line @@ -124,8 +148,24 @@ search: filters: - name: regexp args: "/img/NewIcones/(.+?).png" - title: + title_phase1: selector: a.view-torrent + title_multilang: + text: "{{ .Result.title_phase1 }}" + filters: + - name: re_replace + args: ["(?i)(\\smulti\\s)", " {{ .Config.multilanguage }} "] + title_phase2: + text: "{{ if .Config.multilang }}{{ .Result.title_multilang }}{{ else }}{{ .Result.title_phase1 }}{{ end }}" + title_vostfr: + text: "{{ .Result.title_phase2 }}" + filters: + - name: re_replace + args: ["(?i)(\\svostfr\\s)", " ENGLISH "] + - name: re_replace + args: ["(?i)(\\ssubfrench\\s)", " ENGLISH "] + title: + text: "{{ if .Config.vostfr }}{{ .Result.title_vostfr }}{{ else }}{{ .Result.title_phase2 }}{{ end }}" download: selector: a.view-torrent attribute: href @@ -168,4 +208,9 @@ search: case: "span.badge-extra:contains('Double Upload')": 2 "*": 1 + minimumratio: + text: 0.75 + minimumseedtime: + # 3 days (as seconds = 3 x 24 x 60 x 60) + text: 259200 # UNIT3D