Show More
@@ -1504,7 +1504,7 b'' | |||||
1504 | propagatedBuildInputs = with self; [Babel Beaker FormEncode Mako Markdown MarkupSafe MySQL-python Paste PasteDeploy PasteScript Pygments pygments-markdown-lexer Pylons Pyro4 Routes SQLAlchemy Tempita URLObject WebError WebHelpers WebHelpers2 WebOb WebTest Whoosh alembic amqplib anyjson appenlight-client authomatic backport-ipaddress celery channelstream colander decorator deform docutils gevent gunicorn infrae.cache ipython iso8601 kombu msgpack-python packaging psycopg2 py-gfm pycrypto pycurl pyparsing pyramid pyramid-debugtoolbar pyramid-mako pyramid-beaker pysqlite python-dateutil python-ldap python-memcached python-pam recaptcha-client repoze.lru requests simplejson subprocess32 waitress zope.cachedescriptors dogpile.cache dogpile.core psutil py-bcrypt]; |
|
1504 | propagatedBuildInputs = with self; [Babel Beaker FormEncode Mako Markdown MarkupSafe MySQL-python Paste PasteDeploy PasteScript Pygments pygments-markdown-lexer Pylons Pyro4 Routes SQLAlchemy Tempita URLObject WebError WebHelpers WebHelpers2 WebOb WebTest Whoosh alembic amqplib anyjson appenlight-client authomatic backport-ipaddress celery channelstream colander decorator deform docutils gevent gunicorn infrae.cache ipython iso8601 kombu msgpack-python packaging psycopg2 py-gfm pycrypto pycurl pyparsing pyramid pyramid-debugtoolbar pyramid-mako pyramid-beaker pysqlite python-dateutil python-ldap python-memcached python-pam recaptcha-client repoze.lru requests simplejson subprocess32 waitress zope.cachedescriptors dogpile.cache dogpile.core psutil py-bcrypt]; | |
1505 | src = ./.; |
|
1505 | src = ./.; | |
1506 | meta = { |
|
1506 | meta = { | |
1507 | license = [ { fullName = "AGPLv3, and Commercial License"; } ]; |
|
1507 | license = [ { fullName = "Affero GNU General Public License v3 or later (AGPLv3+)"; } { fullName = "AGPLv3, and Commercial License"; } ]; | |
1508 | }; |
|
1508 | }; | |
1509 | }; |
|
1509 | }; | |
1510 | rhodecode-tools = super.buildPythonPackage { |
|
1510 | rhodecode-tools = super.buildPythonPackage { |
@@ -1,67 +1,76 b'' | |||||
1 | # -*- coding: utf-8 -*- |
|
1 | # -*- coding: utf-8 -*- | |
2 |
|
2 | |||
|
3 | # Copyright (C) 2010-2016 RhodeCode GmbH | |||
|
4 | # | |||
|
5 | # This program is free software: you can redistribute it and/or modify | |||
|
6 | # it under the terms of the GNU Affero General Public License, version 3 | |||
|
7 | # (only), as published by the Free Software Foundation. | |||
|
8 | # | |||
|
9 | # This program is distributed in the hope that it will be useful, | |||
|
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |||
|
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |||
|
12 | # GNU General Public License for more details. | |||
|
13 | # | |||
|
14 | # You should have received a copy of the GNU Affero General Public License | |||
|
15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
|
16 | # | |||
|
17 | # This program is dual-licensed. If you wish to learn more about the | |||
|
18 | # RhodeCode Enterprise Edition, including its added features, Support services, | |||
|
19 | # and proprietary license terms, please see https://rhodecode.com/licenses/ | |||
|
20 | ||||
3 | # Import early to make sure things are patched up properly |
|
21 | # Import early to make sure things are patched up properly | |
4 | from setuptools import setup, find_packages |
|
22 | from setuptools import setup, find_packages | |
5 |
|
23 | |||
6 | import os |
|
24 | import os | |
7 | import sys |
|
25 | import sys | |
|
26 | import pkgutil | |||
8 | import platform |
|
27 | import platform | |
9 |
|
28 | |||
10 | from pip.download import PipSession |
|
29 | from pip.download import PipSession | |
11 | from pip.req import parse_requirements |
|
30 | from pip.req import parse_requirements | |
12 |
|
31 | |||
|
32 | from codecs import open | |||
|
33 | ||||
13 |
|
34 | |||
14 | if sys.version_info < (2, 7): |
|
35 | if sys.version_info < (2, 7): | |
15 | raise Exception('RhodeCode requires Python 2.7 or later') |
|
36 | raise Exception('RhodeCode requires Python 2.7 or later') | |
16 |
|
37 | |||
17 | here = os.path.abspath(os.path.dirname(__file__)) |
|
38 | here = os.path.abspath(os.path.dirname(__file__)) | |
18 |
|
39 | |||
19 | try: |
|
40 | # defines current platform | |
20 | install_reqs = parse_requirements( |
|
41 | __platform__ = platform.system() | |
21 | os.path.join(here, 'requirements.txt'), session=PipSession()) |
|
42 | __license__ = 'AGPLv3, and Commercial License' | |
22 | except TypeError: |
|
43 | __author__ = 'RhodeCode GmbH' | |
23 | # try pip < 6.0.0, that doesn't support session |
|
44 | __url__ = 'https://code.rhodecode.com' | |
24 | install_reqs = parse_requirements( |
|
45 | is_windows = __platform__ in ('Windows',) | |
25 | os.path.join(here, 'requirements.txt')) |
|
|||
26 | install_requirements = [str(ir.req) for ir in install_reqs] |
|
|||
27 |
|
||||
28 | try: |
|
|||
29 | test_reqs = parse_requirements( |
|
|||
30 | os.path.join(here, 'requirements_test.txt'), session=PipSession()) |
|
|||
31 | except TypeError: |
|
|||
32 | # try pip < 6.0.0, that doesn't support session |
|
|||
33 | test_reqs = parse_requirements( |
|
|||
34 | os.path.join(here, 'requirements_test.txt')) |
|
|||
35 | extras = ['configobj'] |
|
|||
36 | test_requirements = [str(ir.req) for ir in test_reqs] + extras |
|
|||
37 |
|
46 | |||
38 |
|
47 | |||
39 | def _get_meta_var(name, data, callback_handler=None): |
|
48 | def _get_requirements(req_filename, exclude=None, extras=None): | |
40 | import re |
|
49 | extras = extras or [] | |
41 | matches = re.compile(r'(?:%s)\s*=\s*(.*)' % name).search(data) |
|
50 | exclude = exclude or [] | |
42 | if matches: |
|
|||
43 | if not callable(callback_handler): |
|
|||
44 | callback_handler = lambda v: v |
|
|||
45 |
|
51 | |||
46 | return callback_handler(eval(matches.groups()[0])) |
|
52 | try: | |
47 |
|
53 | parsed = parse_requirements( | ||
48 | _meta = open(os.path.join(here, 'rhodecode', '__init__.py'), 'rb') |
|
54 | os.path.join(here, req_filename), session=PipSession()) | |
49 | _metadata = _meta.read() |
|
55 | except TypeError: | |
50 | _meta.close() |
|
56 | # try pip < 6.0.0, that doesn't support session | |
|
57 | parsed = parse_requirements(os.path.join(here, req_filename)) | |||
51 |
|
58 | |||
52 | callback = lambda V: ('.'.join(map(str, V[:3])) + '.'.join(V[3:])) |
|
59 | requirements = [] | |
53 | __version__ = open(os.path.join('rhodecode', 'VERSION')).read().strip() |
|
60 | for ir in parsed: | |
54 | __license__ = _get_meta_var('__license__', _metadata) |
|
61 | if ir.req and ir.name not in exclude: | |
55 | __author__ = _get_meta_var('__author__', _metadata) |
|
62 | requirements.append(str(ir.req)) | |
56 | __url__ = _get_meta_var('__url__', _metadata) |
|
63 | return requirements + extras | |
57 | # defines current platform |
|
64 | ||
58 | __platform__ = platform.system() |
|
|||
59 |
|
65 | |||
60 | # Cygwin has different platform identifiers, but they all contain the |
|
66 | # requirements extract | |
61 | # term "CYGWIN" |
|
67 | setup_requirements = ['PasteScript', 'pytest-runner'] | |
62 | is_windows = __platform__ == 'Windows' or 'CYGWIN' in __platform__ |
|
68 | install_requirements = _get_requirements( | |
|
69 | 'requirements.txt', exclude=['setuptools']) | |||
|
70 | test_requirements = _get_requirements( | |||
|
71 | 'requirements_test.txt', extras=['configobj']) | |||
63 |
|
72 | |||
64 | requirements = [ |
|
73 | install_requirements = [ | |
65 | 'Babel', |
|
74 | 'Babel', | |
66 | 'Beaker', |
|
75 | 'Beaker', | |
67 | 'FormEncode', |
|
76 | 'FormEncode', | |
@@ -128,98 +137,72 b' requirements = [' | |||||
128 | 'waitress', |
|
137 | 'waitress', | |
129 | 'zope.cachedescriptors', |
|
138 | 'zope.cachedescriptors', | |
130 | 'dogpile.cache', |
|
139 | 'dogpile.cache', | |
131 | 'dogpile.core' |
|
140 | 'dogpile.core', | |
132 | ] |
|
141 | 'psutil', | |
133 |
|
142 | 'py-bcrypt', | ||
134 | if is_windows: |
|
|||
135 | pass |
|
|||
136 | else: |
|
|||
137 | requirements.append('psutil') |
|
|||
138 | requirements.append('py-bcrypt') |
|
|||
139 |
|
||||
140 |
|
||||
141 | setup_requirements = [ |
|
|||
142 | 'PasteScript', |
|
|||
143 | 'pytest-runner', |
|
|||
144 | ] |
|
|||
145 |
|
||||
146 | dependency_links = [ |
|
|||
147 | ] |
|
|||
148 |
|
||||
149 | classifiers = [ |
|
|||
150 | 'Development Status :: 6 - Mature', |
|
|||
151 | 'Environment :: Web Environment', |
|
|||
152 | 'Framework :: Pylons', |
|
|||
153 | 'Intended Audience :: Developers', |
|
|||
154 | 'Operating System :: OS Independent', |
|
|||
155 | 'Programming Language :: Python', |
|
|||
156 | 'Programming Language :: Python :: 2.7', |
|
|||
157 | ] |
|
143 | ] | |
158 |
|
144 | |||
159 |
|
145 | |||
160 | # additional files from project that goes somewhere in the filesystem |
|
146 | def get_version(): | |
161 | # relative to sys.prefix |
|
147 | version = pkgutil.get_data('rhodecode', 'VERSION') | |
162 | data_files = [] |
|
148 | return version.strip() | |
|
149 | ||||
163 |
|
150 | |||
164 | # additional files that goes into package itself |
|
151 | # additional files that goes into package itself | |
165 | package_data = {'rhodecode': ['i18n/*/LC_MESSAGES/*.mo', ], } |
|
152 | package_data = { | |
|
153 | '': ['*.txt', '*.rst'], | |||
|
154 | 'configs': ['*.ini'], | |||
|
155 | 'rhodecode': ['VERSION', 'i18n/*/LC_MESSAGES/*.mo', ], | |||
|
156 | } | |||
166 |
|
157 | |||
167 |
description = |
|
158 | description = 'Source Code Management Platform' | |
168 | 'for Mercurial and GIT with a built in push/pull server, ' |
|
|||
169 | 'full text search and code-review.') |
|
|||
170 |
|
||||
171 | keywords = ' '.join([ |
|
159 | keywords = ' '.join([ | |
172 |
'rhodecode |
|
160 | 'rhodecode', 'mercurial', 'git', 'svn', | |
173 | 'repo groups', 'ldap', 'repository management', 'hgweb replacement', |
|
161 | 'code review', | |
174 | 'hgwebdir', 'gitweb replacement', 'serving hgweb', |
|
162 | 'repo groups', 'ldap', 'repository management', 'hgweb', | |
|
163 | 'hgwebdir', 'gitweb', 'serving hgweb', | |||
175 | ]) |
|
164 | ]) | |
176 |
|
165 | |||
177 | # long description |
|
166 | ||
178 | README_FILE = 'README.rst' |
|
167 | # README/DESCRIPTION generation | |
179 | CHANGELOG_FILE = 'CHANGES.rst' |
|
168 | readme_file = 'README.rst' | |
|
169 | changelog_file = 'CHANGES.rst' | |||
180 | try: |
|
170 | try: | |
181 |
long_description = open( |
|
171 | long_description = open(readme_file).read() + '\n\n' + \ | |
182 |
open( |
|
172 | open(changelog_file).read() | |
183 |
|
173 | except IOError as err: | ||
184 | except IOError, err: |
|
|||
185 | sys.stderr.write( |
|
174 | sys.stderr.write( | |
186 |
|
|
175 | "[WARNING] Cannot find file specified as long_description (%s)\n " | |
187 |
|
|
176 | "or changelog (%s) skipping that file" % (readme_file, changelog_file)) | |
188 | ) |
|
|||
189 | long_description = description |
|
177 | long_description = description | |
190 |
|
178 | |||
191 | # packages |
|
|||
192 | packages = find_packages() |
|
|||
193 |
|
||||
194 | paster_commands = [ |
|
|||
195 | 'make-config=rhodecode.lib.paster_commands.make_config:Command', |
|
|||
196 | 'setup-rhodecode=rhodecode.lib.paster_commands.setup_rhodecode:Command', |
|
|||
197 | 'update-repoinfo=rhodecode.lib.paster_commands.update_repoinfo:Command', |
|
|||
198 | 'cache-keys=rhodecode.lib.paster_commands.cache_keys:Command', |
|
|||
199 | 'ishell=rhodecode.lib.paster_commands.ishell:Command', |
|
|||
200 | 'upgrade-db=rhodecode.lib.dbmigrate:UpgradeDb', |
|
|||
201 | 'celeryd=rhodecode.lib.celerypylons.commands:CeleryDaemonCommand', |
|
|||
202 | ] |
|
|||
203 |
|
179 | |||
204 | setup( |
|
180 | setup( | |
205 | name='rhodecode-enterprise-ce', |
|
181 | name='rhodecode-enterprise-ce', | |
206 |
version= |
|
182 | version=get_version(), | |
207 | description=description, |
|
183 | description=description, | |
208 | long_description=long_description, |
|
184 | long_description=long_description, | |
209 | keywords=keywords, |
|
185 | keywords=keywords, | |
210 | license=__license__, |
|
186 | license=__license__, | |
211 | author=__author__, |
|
187 | author=__author__, | |
212 | author_email='marcin@rhodecode.com', |
|
188 | author_email='marcin@rhodecode.com', | |
213 | dependency_links=dependency_links, |
|
|||
214 | url=__url__, |
|
189 | url=__url__, | |
215 |
|
|
190 | setup_requires=setup_requirements, | |
|
191 | install_requires=install_requirements, | |||
216 | tests_require=test_requirements, |
|
192 | tests_require=test_requirements, | |
217 | classifiers=classifiers, |
|
193 | zip_safe=False, | |
218 | setup_requires=setup_requirements, |
|
194 | packages=find_packages(exclude=["docs", "tests*"]), | |
219 | data_files=data_files, |
|
195 | package_data=package_data, | |
220 | packages=packages, |
|
|||
221 | include_package_data=True, |
|
196 | include_package_data=True, | |
222 | package_data=package_data, |
|
197 | classifiers=[ | |
|
198 | 'Development Status :: 6 - Mature', | |||
|
199 | 'Environment :: Web Environment', | |||
|
200 | 'Intended Audience :: Developers', | |||
|
201 | 'Operating System :: OS Independent', | |||
|
202 | 'Topic :: Software Development :: Version Control', | |||
|
203 | 'License :: OSI Approved :: Affero GNU General Public License v3 or later (AGPLv3+)', | |||
|
204 | 'Programming Language :: Python :: 2.7', | |||
|
205 | ], | |||
223 | message_extractors={ |
|
206 | message_extractors={ | |
224 | 'rhodecode': [ |
|
207 | 'rhodecode': [ | |
225 | ('**.py', 'python', None), |
|
208 | ('**.py', 'python', None), | |
@@ -229,7 +212,6 b' setup(' | |||||
229 | ('public/**', 'ignore', None), |
|
212 | ('public/**', 'ignore', None), | |
230 | ] |
|
213 | ] | |
231 | }, |
|
214 | }, | |
232 | zip_safe=False, |
|
|||
233 | paster_plugins=['PasteScript', 'Pylons'], |
|
215 | paster_plugins=['PasteScript', 'Pylons'], | |
234 | entry_points={ |
|
216 | entry_points={ | |
235 | 'enterprise.plugins1': [ |
|
217 | 'enterprise.plugins1': [ | |
@@ -249,7 +231,15 b' setup(' | |||||
249 | 'main=pylons.util:PylonsInstaller', |
|
231 | 'main=pylons.util:PylonsInstaller', | |
250 | 'pylons=pylons.util:PylonsInstaller', |
|
232 | 'pylons=pylons.util:PylonsInstaller', | |
251 | ], |
|
233 | ], | |
252 |
'paste.global_paster_command': |
|
234 | 'paste.global_paster_command': [ | |
|
235 | 'make-config=rhodecode.lib.paster_commands.make_config:Command', | |||
|
236 | 'setup-rhodecode=rhodecode.lib.paster_commands.setup_rhodecode:Command', | |||
|
237 | 'update-repoinfo=rhodecode.lib.paster_commands.update_repoinfo:Command', | |||
|
238 | 'cache-keys=rhodecode.lib.paster_commands.cache_keys:Command', | |||
|
239 | 'ishell=rhodecode.lib.paster_commands.ishell:Command', | |||
|
240 | 'upgrade-db=rhodecode.lib.dbmigrate:UpgradeDb', | |||
|
241 | 'celeryd=rhodecode.lib.celerypylons.commands:CeleryDaemonCommand', | |||
|
242 | ], | |||
253 | 'pytest11': [ |
|
243 | 'pytest11': [ | |
254 | 'pylons=rhodecode.tests.pylons_plugin', |
|
244 | 'pylons=rhodecode.tests.pylons_plugin', | |
255 | 'enterprise=rhodecode.tests.plugin', |
|
245 | 'enterprise=rhodecode.tests.plugin', |
General Comments 0
You need to be logged in to leave comments.
Login now