From 4fa0bf4b0c3644078fb9b5c3e7f604f6f6e442d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 14 Jul 2019 10:10:26 +0200 Subject: New upstream version 2.0.5 --- mwc.py | 8 +++++--- mwctools.py | 7 ++++--- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/mwc.py b/mwc.py index 6a48317..22a9dca 100755 --- a/mwc.py +++ b/mwc.py @@ -4,6 +4,8 @@ # Copyright: (2013-2017) Michael Till Beck # License: GPL-2.0+ +#test + import io from lxml import etree import hashlib @@ -78,7 +80,7 @@ def sendmail(receiver, subject, content, sendAsHtml, link, encoding=None): else: if link is not None: content = link + '\n\n' + content - mail = MIMEText(content, 'text', encoding) + mail = MIMEText(content, 'plain', encoding) mail['From'] = config.sender mail['To'] = receiver @@ -93,7 +95,7 @@ def sendmail(receiver, subject, content, sendAsHtml, link, encoding=None): if config.smtpusername is not None: mailsession.login(config.smtpusername, config.smtppwd) - mailsession.sendmail(config.sender, receiver.split(','), mail.as_string()) + mailsession.send_message(mail) # returns a list of all content that is stored locally for a specific site @@ -170,7 +172,7 @@ def pollWebsites(): sessionHashes.append(contenthash) changedContents.append(content) - subject = '[' + site['name'] + '] ' + content.title + subject = '[' + site['name'] + '] ' + ("Update available" if content.title is None else content.title) print(' ' + subject) if config.enableMailNotifications and len(fileHashes) > 0: sendAsHtml = (content.contenttype == 'html') diff --git a/mwctools.py b/mwctools.py index cefbbf0..1dca2e6 100755 --- a/mwctools.py +++ b/mwctools.py @@ -33,12 +33,13 @@ class Receiver(Parser): class Content: - def __init__(self, uri, encoding, title, content, contenttype): + def __init__(self, uri, encoding, title, content, contenttype, additional=None): self.uri = uri self.encoding = encoding self.title = title self.content = content self.contenttype = contenttype + self.additional = additional # returns a short subject line @@ -106,13 +107,13 @@ class CommandReceiver(Receiver): contentList = [] # run command and retrieve output - process = subprocess.Popen(self.command, stdout=subprocess.PIPE, shell=True, close_fds=True) + process = subprocess.Popen(self.command, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, shell=True, close_fds=True) thefile = process.stdout result = thefile.read().decode(self.encoding, errors='ignore') thefile.close() if process.wait() != 0: - raise Exception("process terminated with an error") + raise Exception("process terminated with an error: " + str(process.stderr) + "\n" + result) contentList.append(Content(uri=None, encoding=self.encoding, title=None, content=result, contenttype=self.contenttype)) return contentList -- cgit v1.2.3 From c6476862b6d55d0b434ecbd215941745f956327b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 14 Jul 2019 10:14:24 +0200 Subject: New upstream release --- debian/changelog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/changelog b/debian/changelog index 14f9941..11365cb 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +mwc (2.0.5-1) UNRELEASED; urgency=medium + + * New upstream release. + + -- Jörg Frings-Fürst Sun, 14 Jul 2019 10:10:48 +0200 + mwc (2.0.4-3) unstable; urgency=medium * Declare compliance with Debian Policy 4.2.1 (No changes needed). -- cgit v1.2.3 From 52fac661cccdbbb36b56c56188aba47fcc13206b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 14 Jul 2019 10:16:05 +0200 Subject: Migrate to debhelper 12 --- debian/changelog | 3 +++ 1 file changed, 3 insertions(+) diff --git a/debian/changelog b/debian/changelog index 11365cb..607162c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,6 +1,9 @@ mwc (2.0.5-1) UNRELEASED; urgency=medium * New upstream release. + * Migrate to debhelper 12: + - Change debian/compat to 12. + - Bump minimum debhelper version in debian/control to >= 12. -- Jörg Frings-Fürst Sun, 14 Jul 2019 10:10:48 +0200 -- cgit v1.2.3 From d547528c50ed054dd15aee2f72e68f3773be7d71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 14 Jul 2019 10:17:12 +0200 Subject: Declare compliance with Debian Policy 4.4.0 --- debian/changelog | 1 + debian/compat | 2 +- debian/control | 4 ++-- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/debian/changelog b/debian/changelog index 607162c..5b89caf 100644 --- a/debian/changelog +++ b/debian/changelog @@ -4,6 +4,7 @@ mwc (2.0.5-1) UNRELEASED; urgency=medium * Migrate to debhelper 12: - Change debian/compat to 12. - Bump minimum debhelper version in debian/control to >= 12. + * Declare compliance with Debian Policy 4.4.0 (No changes needed). -- Jörg Frings-Fürst Sun, 14 Jul 2019 10:10:48 +0200 diff --git a/debian/compat b/debian/compat index b4de394..48082f7 100644 --- a/debian/compat +++ b/debian/compat @@ -1 +1 @@ -11 +12 diff --git a/debian/control b/debian/control index 4ea2f78..ba8d83a 100644 --- a/debian/control +++ b/debian/control @@ -3,10 +3,10 @@ Section: utils Priority: optional Maintainer: Jörg Frings-Fürst Build-Depends: - debhelper (>= 11), + debhelper (>= 12), dh-python, python3-all -Standards-Version: 4.2.1 +Standards-Version: 4.4.0 Homepage: https://github.com/Debianguru/MailWebsiteChanges Vcs-Git: git://jff.email/opt/git/mwc.git Vcs-Browser: https://jff.email/cgit/mwc.git -- cgit v1.2.3 From daaa5d43cd25fa32160998c6c15dd8c60a5603b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 14 Jul 2019 10:29:30 +0200 Subject: Move mwcfeedserver from /usr/sbin to /usr/bin --- debian/changelog | 1 + debian/mwc.links | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 5b89caf..6bf1142 100644 --- a/debian/changelog +++ b/debian/changelog @@ -5,6 +5,7 @@ mwc (2.0.5-1) UNRELEASED; urgency=medium - Change debian/compat to 12. - Bump minimum debhelper version in debian/control to >= 12. * Declare compliance with Debian Policy 4.4.0 (No changes needed). + * Move mwcfeedserver from /usr/sbin to /usr/bin. -- Jörg Frings-Fürst Sun, 14 Jul 2019 10:10:48 +0200 diff --git a/debian/mwc.links b/debian/mwc.links index 82885c9..143bb8d 100644 --- a/debian/mwc.links +++ b/debian/mwc.links @@ -1,3 +1,2 @@ /usr/share/mwc/mwc.py /usr/bin/mwc -/usr/share/mwc/mwcfeedserver.py /usr/sbin/mwcfeedserver - +/usr/share/mwc/mwcfeedserver.py /usr/bin/mwcfeedserver -- cgit v1.2.3 From 9bc3ed40e3fe2fea0aa84b9858ba7480dcbae5b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 14 Jul 2019 10:36:51 +0200 Subject: d/changelog: Change distribution to unstable, Change date and time --- debian/changelog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 6bf1142..a626421 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -mwc (2.0.5-1) UNRELEASED; urgency=medium +mwc (2.0.5-1) unstable; urgency=medium * New upstream release. * Migrate to debhelper 12: @@ -7,7 +7,7 @@ mwc (2.0.5-1) UNRELEASED; urgency=medium * Declare compliance with Debian Policy 4.4.0 (No changes needed). * Move mwcfeedserver from /usr/sbin to /usr/bin. - -- Jörg Frings-Fürst Sun, 14 Jul 2019 10:10:48 +0200 + -- Jörg Frings-Fürst Sun, 14 Jul 2019 10:30:27 +0200 mwc (2.0.4-3) unstable; urgency=medium -- cgit v1.2.3 From 749921d2ce9862143db6ef80a6acc7c803d9f0f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 14 Jul 2019 10:54:08 +0200 Subject: d/copyright: Add year 2019 to debian/* --- debian/changelog | 2 ++ debian/copyright | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index a626421..70d54bf 100644 --- a/debian/changelog +++ b/debian/changelog @@ -6,6 +6,8 @@ mwc (2.0.5-1) unstable; urgency=medium - Bump minimum debhelper version in debian/control to >= 12. * Declare compliance with Debian Policy 4.4.0 (No changes needed). * Move mwcfeedserver from /usr/sbin to /usr/bin. + * debian/copyright: + - Add year 2019 to debian/* -- Jörg Frings-Fürst Sun, 14 Jul 2019 10:30:27 +0200 diff --git a/debian/copyright b/debian/copyright index ef90ff9..08e2087 100644 --- a/debian/copyright +++ b/debian/copyright @@ -7,7 +7,7 @@ Copyright: 2013-2017 Michael Till Beck License: GPL-2+ Files: debian/* -Copyright: 2014-2017 Jörg Frings-Fürst +Copyright: 2014-2019 Jörg Frings-Fürst License: GPL-3+ License: GPL-2+ -- cgit v1.2.3