Permalink
Browse files

Prevent installation on Python 2 (Fixes #244)

  • Loading branch information...
thp committed Jun 2, 2018
1 parent 16ee535 commit 651f9ae5b4b6b479f7ec4e7168faafe030e0bae7
Showing with 6 additions and 0 deletions.
  1. +1 −0 CHANGELOG.md
  2. +5 −0 setup.py
View
@@ -8,6 +8,7 @@ The format mostly follows [Keep a Changelog](http://keepachangelog.com/en/1.0.0/
### Changed
- Moved ChangeLog file to CHANGELOG.md and using Keep a Changelog format.
- Force version check in `setup.py`, to exclude Python 2 (Fixes #244)
### Removed
- Old ChangeLog entries
View
@@ -4,18 +4,23 @@
import os
import re
import sys
main_py = open(os.path.join('lib', 'urlwatch', '__init__.py')).read()
m = dict(re.findall("\n__([a-z]+)__ = '([^']+)'", main_py))
docs = re.findall('"""(.*?)"""', main_py, re.DOTALL)
if sys.version_info < (3, 3):
sys.exit('urlwatch requires Python 3.3 or newer')
m['name'] = 'urlwatch'
m['author'], m['author_email'] = re.match(r'(.*) <(.*)>', m['author']).groups()
m['description'], m['long_description'] = docs[0].strip().split('\n\n', 1)
m['install_requires'] = ['minidb', 'PyYAML', 'requests', 'keyring', 'pycodestyle', 'appdirs']
m['scripts'] = ['urlwatch']
m['package_dir'] = {'': 'lib'}
m['packages'] = ['urlwatch']
m['python_requires'] = '>3.3.0'
m['data_files'] = [
('share/man/man1', ['share/man/man1/urlwatch.1']),
('share/urlwatch/examples', [

0 comments on commit 651f9ae

Please sign in to comment.