From 267af572e3c2cee612dad2f9765722bed4198b85 Mon Sep 17 00:00:00 2001 From: Garfield69 Date: Thu, 14 May 2020 21:56:31 +1200 Subject: [PATCH] torrentleech-pl, cinemamovies: optionally drop Polish title prefix. resolves #8615 --- src/Jackett.Common/Definitions/cinemamovies.yml | 13 ++++++++++++- src/Jackett.Common/Definitions/torrentleech-pl.yml | 13 ++++++++++++- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/src/Jackett.Common/Definitions/cinemamovies.yml b/src/Jackett.Common/Definitions/cinemamovies.yml index 9ebe182e6..fc5b46a52 100644 --- a/src/Jackett.Common/Definitions/cinemamovies.yml +++ b/src/Jackett.Common/Definitions/cinemamovies.yml @@ -44,6 +44,10 @@ settings: type: info label: How to get the Cookie default: "
  1. Login to this tracker with your browser
  2. Open the DevTools panel by pressing F12
  3. Select the Network tab
  4. Click on the Doc button
  5. Refresh the page by pressing F5
  6. Select the Headers tab
  7. Find 'cookie:' in the Request Headers section
  8. Select and Copy the whole cookie string (everything after 'cookie: ') and Paste here.
" + - name: drop_polish_prefix + type: checkbox + label: Drop the Polish title prefix + default: false - name: sort type: select label: Sort requested from site @@ -94,8 +98,15 @@ search: filters: - name: querystring args: cat - title: + title_raw: selector: a[href^="details.php?id="] + title_stripped: + selector: a[href^="details.php?id="] + filters: + - name: re_replace + args: ["^(.* / )(.*)$", "$2"] + title: + text: "{{ if .Config.drop_polish_prefix }}{{ .Result.title_stripped }}{{ else }}{{ .Result.title_raw }}{{ end }}" details: selector: a[href^="details.php?id="] attribute: href diff --git a/src/Jackett.Common/Definitions/torrentleech-pl.yml b/src/Jackett.Common/Definitions/torrentleech-pl.yml index edc868040..4f3e230a9 100644 --- a/src/Jackett.Common/Definitions/torrentleech-pl.yml +++ b/src/Jackett.Common/Definitions/torrentleech-pl.yml @@ -51,6 +51,10 @@ settings: type: info label: How to get the Cookie default: "
  1. Login to this tracker with your browser
  2. Open the DevTools panel by pressing F12
  3. Select the Network tab
  4. Click on the Doc button
  5. Refresh the page by pressing F5
  6. Select the Headers tab
  7. Find 'cookie:' in the Request Headers section
  8. Select and Copy the whole cookie string (everything after 'cookie: ') and Paste here.
" + - name: drop_polish_prefix + type: checkbox + label: Drop the Polish title prefix + default: false # - name: sort # type: select # label: Sort requested from site @@ -111,8 +115,15 @@ search: filters: - name: querystring args: cat - title: + title_raw: selector: a[href^="details.php?id="] + title_stripped: + selector: a[href^="details.php?id="] + filters: + - name: re_replace + args: ["^(.* / )(.*)$", "$2"] + title: + text: "{{ if .Config.drop_polish_prefix }}{{ .Result.title_stripped }}{{ else }}{{ .Result.title_raw }}{{ end }}" details: selector: a[href^="details.php?id="] attribute: href