From 8e47b0de30a25d0fd5dfb518bfe4e1e7beff93fd Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Tue, 15 Jul 2014 16:27:44 +0200 Subject: Key attributes cleanup for account, container and crypter plugins --- module/plugins/crypter/ChipDe.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index 529ec6918..8e48b1085 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -6,13 +6,16 @@ from module.plugins.Crypter import Crypter class ChipDe(Crypter): __name__ = "ChipDe" + __version__ = "0.1" __type__ = "crypter" + __pattern__ = r'http://(?:www\.)?chip.de/video/.*\.html' - __version__ = "0.1" + __description__ = """Chip.de decrypter plugin""" __author_name__ = "4Christopher" __author_mail__ = "4Christopher@gmx.de" + def decrypt(self, pyfile): self.html = self.load(pyfile.url) try: -- cgit v1.2.3 From a1e78f33dc2b0b6777fdcbc415673f3965b25542 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Wed, 16 Jul 2014 00:46:26 +0200 Subject: Prefer self.urls and self.packages for adding links --- module/plugins/crypter/ChipDe.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index 8e48b1085..f59903170 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -19,9 +19,9 @@ class ChipDe(Crypter): def decrypt(self, pyfile): self.html = self.load(pyfile.url) try: - url = re.search(r'"(http://video.chip.de/\d+?/.*)"', self.html).group(1) - self.logDebug('The file URL is %s' % url) + f = re.search(r'"(http://video.chip.de/\d+?/.*)"', self.html) except: self.fail('Failed to find the URL') - - self.packages.append((pyfile.package().name, [url], pyfile.package().folder)) + else: + self.urls = [f.group(1)] + self.logDebug('The file URL is %s' % self.urls[0]) -- cgit v1.2.3 From ba916633f2bedb04c7358000b91aed69f52e8e43 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Fri, 1 Aug 2014 19:35:59 +0200 Subject: Remove trailing whitespaces + remove license headers + import urllib methods directly + sort and fix key attributes + use save_join instead join + sort some import declarations + other minor code cosmetics --- module/plugins/crypter/ChipDe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index f59903170..a75cc5e0e 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -6,8 +6,8 @@ from module.plugins.Crypter import Crypter class ChipDe(Crypter): __name__ = "ChipDe" - __version__ = "0.1" __type__ = "crypter" + __version__ = "0.1" __pattern__ = r'http://(?:www\.)?chip.de/video/.*\.html' -- cgit v1.2.3 From 0d220d634e512d89bda540f91c643b361c82ea8a Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 27 Sep 2014 01:38:32 +0200 Subject: Logging string cosmetics --- module/plugins/crypter/ChipDe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index a75cc5e0e..e545efa54 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -24,4 +24,4 @@ class ChipDe(Crypter): self.fail('Failed to find the URL') else: self.urls = [f.group(1)] - self.logDebug('The file URL is %s' % self.urls[0]) + self.logDebug("The file URL is %s" % self.urls[0]) -- cgit v1.2.3 From b0868ae6446078bacf1635dde5e4ab316b4a94cb Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Tue, 7 Oct 2014 18:57:59 +0200 Subject: New __authors__ key replaces __author_name__ and __author_mail__ + Whitespaces and EOF fixup --- module/plugins/crypter/ChipDe.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index e545efa54..9aac1efa4 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -12,8 +12,7 @@ class ChipDe(Crypter): __pattern__ = r'http://(?:www\.)?chip.de/video/.*\.html' __description__ = """Chip.de decrypter plugin""" - __author_name__ = "4Christopher" - __author_mail__ = "4Christopher@gmx.de" + __authors__ = [("4Christopher", "4Christopher@gmx.de")] def decrypt(self, pyfile): -- cgit v1.2.3 From ae7a7e66981456e5bbe2b54006d79b6f907be7a4 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Wed, 8 Oct 2014 20:18:13 +0200 Subject: Add __license__ key attribute to plugins --- module/plugins/crypter/ChipDe.py | 1 + 1 file changed, 1 insertion(+) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index 9aac1efa4..7752ee3bb 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -12,6 +12,7 @@ class ChipDe(Crypter): __pattern__ = r'http://(?:www\.)?chip.de/video/.*\.html' __description__ = """Chip.de decrypter plugin""" + __license__ = "GPLv3" __authors__ = [("4Christopher", "4Christopher@gmx.de")] -- cgit v1.2.3 From f76e5c2336718dca9da8033ba22cd83c72c7b3b3 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 11 Oct 2014 15:14:28 +0200 Subject: Pattern update 1 --- module/plugins/crypter/ChipDe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index 7752ee3bb..a4d6ad285 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -19,7 +19,7 @@ class ChipDe(Crypter): def decrypt(self, pyfile): self.html = self.load(pyfile.url) try: - f = re.search(r'"(http://video.chip.de/\d+?/.*)"', self.html) + f = re.search(r'"(http://video\.chip\.de/.+)"', self.html) except: self.fail('Failed to find the URL') else: -- cgit v1.2.3 From c5d1a4fd8943877c6d2eb3843e0de725dba5191e Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 11 Oct 2014 15:09:53 +0200 Subject: Pattern update 2 --- module/plugins/crypter/ChipDe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index a4d6ad285..317f73e4c 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -9,7 +9,7 @@ class ChipDe(Crypter): __type__ = "crypter" __version__ = "0.1" - __pattern__ = r'http://(?:www\.)?chip.de/video/.*\.html' + __pattern__ = r'http://(?:www\.)?chip\.de/video/.*\.html' __description__ = """Chip.de decrypter plugin""" __license__ = "GPLv3" -- cgit v1.2.3 From e3f5280529921100f48bb8a79853bf480c7611e4 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 25 Oct 2014 02:53:05 +0200 Subject: Replace single quotes with doubles in self.error and self.fail msg --- module/plugins/crypter/ChipDe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index 317f73e4c..4ef476895 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -21,7 +21,7 @@ class ChipDe(Crypter): try: f = re.search(r'"(http://video\.chip\.de/.+)"', self.html) except: - self.fail('Failed to find the URL') + self.fail("Failed to find the URL") else: self.urls = [f.group(1)] self.logDebug("The file URL is %s" % self.urls[0]) -- cgit v1.2.3 From 9f2ebe486a3e155fb6a60e07cccb77ab6a772eb2 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sun, 26 Oct 2014 02:31:54 +0200 Subject: Extend translation support in plugins + a lot of code cosmetics and typo fixes --- module/plugins/crypter/ChipDe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index 4ef476895..26805b5b8 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -21,7 +21,7 @@ class ChipDe(Crypter): try: f = re.search(r'"(http://video\.chip\.de/.+)"', self.html) except: - self.fail("Failed to find the URL") + self.fail(_("Failed to find the URL")) else: self.urls = [f.group(1)] self.logDebug("The file URL is %s" % self.urls[0]) -- cgit v1.2.3 From 885f8ed782e64d9e73367905e642a84d0a8999f1 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Tue, 28 Oct 2014 04:01:38 +0100 Subject: Update __config__ --- module/plugins/crypter/ChipDe.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index 26805b5b8..befa9ddc2 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -10,6 +10,8 @@ class ChipDe(Crypter): __version__ = "0.1" __pattern__ = r'http://(?:www\.)?chip\.de/video/.*\.html' + __config__ = [("use_subfolder", "bool", "Save package to subfolder", True), + ("subfolder_per_package", "bool", "Create a subfolder for each package", True)] __description__ = """Chip.de decrypter plugin""" __license__ = "GPLv3" -- cgit v1.2.3 From 34984dae733c3f3d47b41a0acfba3724d53c65a1 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Tue, 28 Oct 2014 16:52:10 +0100 Subject: Code cosmetics: plugin class attributes --- module/plugins/crypter/ChipDe.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index befa9ddc2..59ed6559e 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -5,8 +5,8 @@ from module.plugins.Crypter import Crypter class ChipDe(Crypter): - __name__ = "ChipDe" - __type__ = "crypter" + __name__ = "ChipDe" + __type__ = "crypter" __version__ = "0.1" __pattern__ = r'http://(?:www\.)?chip\.de/video/.*\.html' @@ -14,8 +14,8 @@ class ChipDe(Crypter): ("subfolder_per_package", "bool", "Create a subfolder for each package", True)] __description__ = """Chip.de decrypter plugin""" - __license__ = "GPLv3" - __authors__ = [("4Christopher", "4Christopher@gmx.de")] + __license__ = "GPLv3" + __authors__ = [("4Christopher", "4Christopher@gmx.de")] def decrypt(self, pyfile): -- cgit v1.2.3 From 6151e81fa0b325dffda3da4228d5821e73db3ef3 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Tue, 9 Dec 2014 01:19:46 +0100 Subject: Fix __version__ format in some plugins --- module/plugins/crypter/ChipDe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index 59ed6559e..b342cd1bf 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -7,7 +7,7 @@ from module.plugins.Crypter import Crypter class ChipDe(Crypter): __name__ = "ChipDe" __type__ = "crypter" - __version__ = "0.1" + __version__ = "0.10" __pattern__ = r'http://(?:www\.)?chip\.de/video/.*\.html' __config__ = [("use_subfolder", "bool", "Save package to subfolder", True), -- cgit v1.2.3 From 717faa6d2f2a0017b81516a9d01656487f03be28 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 27 Dec 2014 13:56:01 +0100 Subject: More plugin __pattern__ improved (crypter ones this time) --- module/plugins/crypter/ChipDe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/crypter/ChipDe.py') diff --git a/module/plugins/crypter/ChipDe.py b/module/plugins/crypter/ChipDe.py index b342cd1bf..133e5a005 100644 --- a/module/plugins/crypter/ChipDe.py +++ b/module/plugins/crypter/ChipDe.py @@ -9,7 +9,7 @@ class ChipDe(Crypter): __type__ = "crypter" __version__ = "0.10" - __pattern__ = r'http://(?:www\.)?chip\.de/video/.*\.html' + __pattern__ = r'http://(?:www\.)?chip\.de/video/.+\.html' __config__ = [("use_subfolder", "bool", "Save package to subfolder", True), ("subfolder_per_package", "bool", "Create a subfolder for each package", True)] -- cgit v1.2.3