comparison setup.py @ 8215:928bc1d8b279 default-i18n

Merge from default
author Mads Kiilerich <mads@kiilerich.com>
date Thu, 06 Feb 2020 01:19:23 +0100
parents 01aca0a4f876
children d122a9532630
comparison
equal deleted inserted replaced
8214:460e7d2d1b38 8215:928bc1d8b279
1 #!/usr/bin/env python2 1 #!/usr/bin/env python3
2 # -*- coding: utf-8 -*- 2 # -*- coding: utf-8 -*-
3 import os 3 import os
4 import platform 4 import platform
5 import sys 5 import sys
6 6
7 import setuptools 7 import setuptools
8 # monkey patch setuptools to use distutils owner/group functionality 8 # monkey patch setuptools to use distutils owner/group functionality
9 from setuptools.command import sdist 9 from setuptools.command import sdist
10 10
11 11
12 if sys.version_info < (2, 6) or sys.version_info >= (3,): 12 if sys.version_info < (3, 6):
13 raise Exception('Kallithea requires python 2.7') 13 raise Exception('Kallithea requires Python 3.6 or later')
14 14
15 15
16 here = os.path.abspath(os.path.dirname(__file__)) 16 here = os.path.abspath(os.path.dirname(__file__))
17 17
18 18
23 if not callable(callback_handler): 23 if not callable(callback_handler):
24 callback_handler = lambda v: v 24 callback_handler = lambda v: v
25 25
26 return callback_handler(eval(matches.groups()[0])) 26 return callback_handler(eval(matches.groups()[0]))
27 27
28 _meta = open(os.path.join(here, 'kallithea', '__init__.py'), 'rb') 28 _meta = open(os.path.join(here, 'kallithea', '__init__.py'), 'r')
29 _metadata = _meta.read() 29 _metadata = _meta.read()
30 _meta.close() 30 _meta.close()
31 31
32 callback = lambda V: ('.'.join(map(str, V[:3])) + '.'.join(V[3:])) 32 callback = lambda V: ('.'.join(map(str, V[:3])) + '.'.join(V[3:]))
33 __version__ = _get_meta_var('VERSION', _metadata, callback) 33 __version__ = _get_meta_var('VERSION', _metadata, callback)
38 __platform__ = platform.system() 38 __platform__ = platform.system()
39 39
40 is_windows = __platform__ in ['Windows'] 40 is_windows = __platform__ in ['Windows']
41 41
42 requirements = [ 42 requirements = [
43 "alembic >= 0.8.0, < 1.1", 43 "alembic >= 1.0.10, < 1.1",
44 "gearbox >= 0.1.0, < 1", 44 "gearbox >= 0.1.0, < 1",
45 "waitress >= 0.8.8, < 1.4", 45 "waitress >= 0.8.8, < 1.4",
46 "WebOb >= 1.7, < 1.9", 46 "WebOb >= 1.8, < 1.9",
47 "backlash >= 0.1.2, < 1", 47 "backlash >= 0.1.2, < 1",
48 "TurboGears2 >= 2.3.10, < 2.5", 48 "TurboGears2 >= 2.4, < 2.5",
49 "tgext.routes >= 0.2.0, < 1", 49 "tgext.routes >= 0.2.0, < 1",
50 "Beaker >= 1.7.0, < 2", 50 "Beaker >= 1.10.1, < 2",
51 "WebHelpers >= 1.3, < 1.4",
52 "WebHelpers2 >= 2.0, < 2.1", 51 "WebHelpers2 >= 2.0, < 2.1",
53 "FormEncode >= 1.3.0, < 1.4", 52 "FormEncode >= 1.3.1, < 1.4",
54 "SQLAlchemy >= 1.1, < 1.4", 53 "SQLAlchemy >= 1.2.9, < 1.4",
55 "Mako >= 0.9.0, < 1.1", 54 "Mako >= 0.9.1, < 1.1",
56 "Pygments >= 2.2.0, < 2.5", 55 "Pygments >= 2.2.0, < 2.5",
57 "Whoosh >= 2.5.0, < 2.8", 56 "Whoosh >= 2.7.1, < 2.8",
58 "celery >= 3.1, < 4.0", # TODO: celery 4 doesn't work 57 "celery >= 3.1, < 4.0", # TODO: celery 4 doesn't work
59 "Babel >= 1.3, < 2.8", 58 "Babel >= 1.3, < 2.8",
60 "python-dateutil >= 1.5.0, < 2.9", 59 "python-dateutil >= 2.1.0, < 2.9",
61 "Markdown >= 2.2.1, < 3.2", 60 "Markdown >= 2.2.1, < 3.2",
62 "docutils >= 0.11, < 0.15", 61 "docutils >= 0.11, < 0.15",
63 "URLObject >= 2.3.4, < 2.5", 62 "URLObject >= 2.3.4, < 2.5",
64 "Routes >= 1.13, < 2", # TODO: bumping to 2.0 will make test_file_annotation fail 63 "Routes >= 2.0, < 2.5",
65 "dulwich >= 0.14.1, < 0.20", 64 "dulwich >= 0.19.0, < 0.20",
66 "mercurial >= 4.5, < 5.3", 65 "mercurial >= 5.2, < 5.4",
67 "decorator >= 3.3.2, < 4.5", 66 "decorator >= 4.2.1, < 4.5",
68 "Paste >= 2.0.3, < 3.1", 67 "Paste >= 2.0.3, < 3.1",
69 "bleach >= 3.0, < 3.2", 68 "bleach >= 3.0, < 3.2",
70 "Click >= 7.0, < 8", 69 "Click >= 7.0, < 8",
71 "ipaddr >= 2.1.10, < 2.3", 70 "ipaddr >= 2.2.0, < 2.3",
71 "paginate >= 0.5, < 0.6",
72 "paginate_sqlalchemy >= 0.3.0, < 0.4",
72 ] 73 ]
73 74
74 if not is_windows: 75 if not is_windows:
75 requirements.append("bcrypt >= 3.1.0, < 3.2") 76 requirements.append("bcrypt >= 3.1.0, < 3.2")
76 77
82 'Environment :: Web Environment', 83 'Environment :: Web Environment',
83 'Framework :: Pylons', 84 'Framework :: Pylons',
84 'Intended Audience :: Developers', 85 'Intended Audience :: Developers',
85 'License :: OSI Approved :: GNU General Public License (GPL)', 86 'License :: OSI Approved :: GNU General Public License (GPL)',
86 'Operating System :: OS Independent', 87 'Operating System :: OS Independent',
87 'Programming Language :: Python', 88 'Programming Language :: Python :: 3.6',
88 'Programming Language :: Python :: 2.7', 89 'Programming Language :: Python :: 3.7',
90 'Programming Language :: Python :: 3.8',
89 'Topic :: Software Development :: Version Control', 91 'Topic :: Software Development :: Version Control',
90 ] 92 ]
91 93
92 94
93 # additional files from project that goes somewhere in the filesystem 95 # additional files from project that goes somewhere in the filesystem