summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
Diffstat (limited to 'debian')
-rw-r--r--debian/README.source18
-rw-r--r--debian/changelog15
-rw-r--r--debian/control2
-rw-r--r--debian/patches/0100-config.diff115
-rw-r--r--debian/patches/0105-try_mail.diff52
-rw-r--r--debian/patches/0110-syslog.diff96
-rw-r--r--debian/patches/0115-Add_header.patch50
-rw-r--r--debian/patches/series4
8 files changed, 27 insertions, 325 deletions
diff --git a/debian/README.source b/debian/README.source
new file mode 100644
index 0000000..e4f2b3d
--- /dev/null
+++ b/debian/README.source
@@ -0,0 +1,18 @@
+Hello,
+
+now I use the branching model from Vincent Driessen[1].
+
+I use the gitflow-avh[2]. with the Documentation[3].
+The Debian package can be found here[4].
+
+Please upload unattended uploads use a branch feature/<your title>.
+
+
+Many thanks.
+
+ -- Jörg Frings-Fürst <debian@jff-webhosting.net> Fri, 02 Jun 2017 19:00:40 +0200
+
+[1] http://nvie.com/posts/a-successful-git-branching-model/
+[2] https://github.com/petervanderdoes/gitflow-avh
+[3] https://github.com/petervanderdoes/gitflow-avh/wiki
+[4] https://tracker.debian.org/pkg/git-flow
diff --git a/debian/changelog b/debian/changelog
index 48ee0e8..716efc8 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,19 +1,20 @@
-mwc (1.7.5-1) UNRELEASED; urgency=medium
+mwc (2.0.4-1) unstable; urgency=medium
- * New upstream release.
- * Renumbering patches.
- * debian/patches/0105-try_mail.diff:
- - Replace undefined printf with print (Closes: #860494).
+ * New upstream release:
+ - Remove now unusable patches and therefore the printf function
+ (Closes: #860494).
+ - Add more Parameter needed at some websites (Closes: #862004).
* Rewrite debian/watch for archives without "v" in front of the version.
- * Bump Standards-Version to 3.9.8.
+ * Declare compliance with Debian Policy 4.1.1. (No changes needed).
* Bump compatlevel to 10 (no changes required):
- Change debian/compat to 10.
- At debian/control change requested version of debhelper to >= 10.
* At debian/control change Vcs-Browser to secure URI.
* debian/copyright:
- Refresh copyright year at * and debian/*.
+ * New README.source to explain the branching model used.
- -- Jörg Frings-Fürst <debian@jff-webhosting.net> Tue, 18 Apr 2017 11:06:04 +0200
+ -- Jörg Frings-Fürst <debian@jff-webhosting.net> Sun, 01 Oct 2017 20:21:11 +0200
mwc (1.7.2-3) unstable; urgency=medium
diff --git a/debian/control b/debian/control
index 70dd2d3..792ce2a 100644
--- a/debian/control
+++ b/debian/control
@@ -6,7 +6,7 @@ Build-Depends:
debhelper (>= 10),
dh-python,
python3-all
-Standards-Version: 3.9.8
+Standards-Version: 4.1.1
Homepage: https://github.com/Debianguru/MailWebsiteChanges
Vcs-Git: git://anonscm.debian.org/collab-maint/mwc.git
Vcs-Browser: https://anonscm.debian.org/cgit/collab-maint/mwc.git
diff --git a/debian/patches/0100-config.diff b/debian/patches/0100-config.diff
deleted file mode 100644
index ce4dba7..0000000
--- a/debian/patches/0100-config.diff
+++ /dev/null
@@ -1,115 +0,0 @@
-Description: add loading config from every path
- Add loading config from ervery path
- Separation data / program
-Author: Jörg Frings-Fürst <jff@jff-webhosting.net>
-Last-Update: 2014-05-12
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
-Index: trunk/mwc.py
-===================================================================
---- trunk.orig/mwc.py
-+++ trunk/mwc.py
-@@ -319,7 +319,7 @@ def pollWebsites():
-
- if __name__ == "__main__":
-
-- configMod = 'config'
-+ configMod = '/etc/mwc/mwc-config'
- dryrun = None
-
- try:
-@@ -335,9 +335,24 @@ if __name__ == "__main__":
- configMod = arg
- elif opt in ('-d', '--dry-run'):
- dryrun = arg
--
-- config = importlib.import_module(configMod)
--
-+ #
-+ # add code to load config from nonsystem path
-+ # and change to datadir
-+ #
-+ try:
-+ path = os.path.dirname(configMod)
-+ fullname = os.path.basename(configMod)
-+ sys.path.append(path)
-+ config = importlib.import_module(fullname)
-+ except:
-+ print('Error: loading config')
-+ sys.exit(2)
-+ try:
-+ os.chdir(config.datadir)
-+ except:
-+ print('Error: datadir not found')
-+ sys.exit(3)
-+
- if dryrun:
- for site in config.sites:
- if site['shortname'] == dryrun:
-Index: trunk/config_template.py
-===================================================================
---- trunk.orig/config_template.py
-+++ trunk/config_template.py
-@@ -1,5 +1,3 @@
--import os.path
--
- # Copyright: (2013-2014) Michael Till Beck <Debianguru@gmx.de>
- # License: GPL-2.0+
-
-@@ -46,11 +44,11 @@ sender = 'me@mymail.com'
- smtphost = 'mysmtpprovider.com'
- useTLS = True
- smtpport = 587
--smtpusername = sender
-+smtpusername = 'sender'
- smtppwd = 'mypassword'
- receiver = 'me2@mymail.com'
-
--os.chdir('/var/cache/mwc')
-+datadir'/var/cache/mwc'
-
- enableRSSFeed = True
- rssfile = 'feed.xml'
-Index: trunk/mwcfeedserver.py
-===================================================================
---- trunk.orig/mwcfeedserver.py
-+++ trunk/mwcfeedserver.py
-@@ -6,6 +6,7 @@
- import http.server
- import socketserver
- import importlib
-+import os
- import sys
- import getopt
-
-@@ -31,13 +32,26 @@ for opt, arg in opts:
- elif opt in ('-p', '--port'):
- port = int(arg)
-
--config = importlib.import_module(configMod)
--
-+#
-+# add code to load config from nonsystem path
-+# and change to datadir
-+#
-+try:
-+ path = os.path.dirname(configMod)
-+ fullname = os.path.basename(configMod)
-+ sys.path.append(path)
-+ config = importlib.import_module(fullname)
-+except:
-+ print('Error: loading config')
-+ sys.exit(2)
-
- handler = http.server.SimpleHTTPRequestHandler
-
- httpd = socketserver.TCPServer((bind, port), handler)
-
- print('Bond to ' + bind + ', listening on port ' + str(port))
--httpd.serve_forever()
--
-+try:
-+ httpd.serve_forever()
-+except KeyboardInterrupt:
-+ pass
-+httpd.server_close()
diff --git a/debian/patches/0105-try_mail.diff b/debian/patches/0105-try_mail.diff
deleted file mode 100644
index d390b6d..0000000
--- a/debian/patches/0105-try_mail.diff
+++ /dev/null
@@ -1,52 +0,0 @@
-Description: try / except around mail functions
- add try / except around mail functions to
- prevent python errors messages
-Author: Jörg Frings-Fürst <debian@jff-webhosting.net>
-Forwarded: via mail
-Applied-Upstream: <version|URL|commit, identifies patches merged upstream, optional>
-Reviewed-by:
-Last-Update: 2014-05-22
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
-Index: trunk/mwc.py
-===================================================================
---- trunk.orig/mwc.py
-+++ trunk/mwc.py
-@@ -225,16 +225,27 @@ def sendmail(receiver, subject, content,
- mail['Subject'] = Header(subject, defaultEncoding)
-
- # initialize session once, not each time this method gets called
-- if mailsession is None:
-- mailsession = smtplib.SMTP(config.smtphost, config.smtpport)
-- if config.useTLS:
-- mailsession.ehlo()
-- mailsession.starttls()
-- if config.smtpusername is not None:
-- mailsession.login(config.smtpusername, config.smtppwd)
--
-- mailsession.sendmail(config.sender, receiver.split(','), mail.as_string())
--
-+ #
-+ # add try / except to open mailsession
-+ #
-+ try:
-+ if mailsession is None:
-+ mailsession = smtplib.SMTP(config.smtphost, config.smtpport)
-+ if config.useTLS:
-+ mailsession.ehlo()
-+ mailsession.starttls()
-+ mailsession.login(config.smtpusername, config.smtppwd)
-+ #
-+ # add try / except to send mail
-+ #
-+ except:
-+ print('Error: Open smtp-session')
-+ exit(4)
-+ try:
-+ mailsession.sendmail(config.sender, receiver.split(','), mail.as_string())
-+ except:
-+ print('Error: sendmail')
-+ exit(5)
-
- # returns a list of all content that is stored locally for a specific site
- def getFileContents(shortname):
diff --git a/debian/patches/0110-syslog.diff b/debian/patches/0110-syslog.diff
deleted file mode 100644
index 12d629d..0000000
--- a/debian/patches/0110-syslog.diff
+++ /dev/null
@@ -1,96 +0,0 @@
-Description: add syslog messages on errors
-Author: Jörg Frings-Fürst <debian@jffwebhosting.net>
-Forwarded: via mail
-Last-Update: 2014-05-22
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
-Index: trunk/mwc.py
-===================================================================
---- trunk.orig/mwc.py
-+++ trunk/mwc.py
-@@ -19,6 +19,7 @@ import os
- import sys
- import getopt
- import traceback
-+import syslog
-
- import subprocess
-
-@@ -227,25 +228,28 @@ def sendmail(receiver, subject, content,
- # initialize session once, not each time this method gets called
- #
- # add try / except to open mailsession
-- #
-+ #
-+
- try:
-- if mailsession is None:
-- mailsession = smtplib.SMTP(config.smtphost, config.smtpport)
-- if config.useTLS:
-- mailsession.ehlo()
-- mailsession.starttls()
-- mailsession.login(config.smtpusername, config.smtppwd)
-- #
-+ if mailsession is None:
-+ mailsession = smtplib.SMTP(config.smtphost, config.smtpport)
-+ if config.useTLS:
-+ mailsession.ehlo()
-+ mailsession.starttls()
-+ mailsession.login(config.smtpusername, config.smtppwd)
-+ except:
-+ print('Error: Open smtp-session')
-+ syslog.syslog(syslog.LOG_ERR, 'can not open smtp session')
-+ exit(4)
-+ #
- # add try / except to send mail
- #
-+ try:
-+ mailsession.sendmail(config.sender, receiver.split(','), mail.as_string())
- except:
-- print('Error: Open smtp-session')
-- exit(4)
-- try:
-- mailsession.sendmail(config.sender, receiver.split(','), mail.as_string())
-- except:
-- print('Error: sendmail')
-- exit(5)
-+ print('Error: sendmail')
-+ syslog.syslog(syslog.LOG_ERR, 'error on sendmail')
-+ exit(5)
-
- # returns a list of all content that is stored locally for a specific site
- def getFileContents(shortname):
-@@ -332,7 +336,11 @@ if __name__ == "__main__":
-
- configMod = '/etc/mwc/mwc-config'
- dryrun = None
--
-+
-+ #
-+ # add syslog open
-+ #
-+ syslog.openlog()
- try:
- opts, args = getopt.getopt(sys.argv[1:], 'hc:d:', ['help', 'config=', 'dry-run='])
- except getopt.GetoptError:
-@@ -357,11 +365,13 @@ if __name__ == "__main__":
- config = importlib.import_module(fullname)
- except:
- print('Error: loading config')
-+ syslog.syslog(syslog.LOG_ERR, 'can not found / load mwc-config')
- sys.exit(2)
- try:
- os.chdir(config.datadir)
- except:
- print('Error: datadir not found')
-+ syslog.syslog(syslog.LOG_ERR, 'datadir not found')
- sys.exit(3)
-
- if dryrun:
-@@ -383,3 +393,5 @@ if __name__ == "__main__":
- mailsession.quit()
- mailsession = None
-
-+ syslog.closelog()
-+
-\ No newline at end of file
diff --git a/debian/patches/0115-Add_header.patch b/debian/patches/0115-Add_header.patch
deleted file mode 100644
index 6ce0c15..0000000
--- a/debian/patches/0115-Add_header.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-Description: Add Header Accept
-Author: Jörg Frings-Fürst <debian@jff-webhosting.net>
-Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=862004
-Forwarded: https://github.com/Debianguru/MailWebsiteChanges/issues/11
-Last-Update: 2017-05-07
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
-Index: trunk/mwc.py
-===================================================================
---- trunk.orig/mwc.py
-+++ trunk/mwc.py
-@@ -91,6 +91,8 @@ def parseSite(site):
- req = urllib.request.Request(uri)
- if 'user-agent' in site:
- req.add_header('User-Agent', site['user-agent'])
-+ if 'accept' in site:
-+ req.add_header('Accept', site['accept'])
- file = urllib.request.urlopen(req)
-
-
-Index: trunk/README.md
-===================================================================
---- trunk.orig/README.md
-+++ trunk/README.md
-@@ -59,7 +59,9 @@ sites = [
- * <b>user-agent</b> (optional)
- Defines the user agent string, e.g.,
- 'user-agent': 'Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:49.0) Gecko/20100101 Firefox/49.0'
--
-+ * <b>accept</b> (optional)
-+ Defines the accept string, e.g.,
-+ 'accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'
-
- * We collect some XPath/CSS snippets at this place: <a href="https://github.com/Debianguru/MailWebsiteChanges/wiki/snippets">Snippet collection</a> - please feel free to add your own definitions!
-
-Index: trunk/config_template.py
-===================================================================
---- trunk.orig/config_template.py
-+++ trunk/config_template.py
-@@ -12,7 +12,9 @@ sites = [
- 'contentxpath': '//div',
- 'titleregex': '',
- 'contentregex': '',
-- 'encoding': 'utf-8'},
-+ 'encoding': 'utf-8',
-+ 'user-agent': 'Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:49.0) Gecko/20100101 Firefox/49.0',
-+ 'accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'},
-
- {'shortname': 'mywebsite2',
- 'uri': 'http://www.mywebsite2.com/info',
diff --git a/debian/patches/series b/debian/patches/series
index a06ba62..e69de29 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +0,0 @@
-0100-config.diff
-0105-try_mail.diff
-0110-syslog.diff
-#0115-Add_header.patch