-
Notifications
You must be signed in to change notification settings - Fork 15
/
setup.py
112 lines (104 loc) · 3.08 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
# -*- coding: utf-8 -*-
#
# This file is part of DoJSON
# Copyright (C) 2015 CERN.
#
# DoJSON is free software; you can redistribute it and/or
# modify it under the terms of the Revised BSD License; see LICENSE
# file for more details.
"""CDS DoJSON extension"""
import os
import re
from setuptools import setup
# Get the version string. Cannot be done with import!
with open(os.path.join('cds_dojson', 'version.py'), 'rt') as f:
version = re.search(
'__version__\s*=\s*"(?P<version>.*)"\n',
f.read()
).group('version')
tests_require = [
'check-manifest>=0.25',
'coverage>=4.0',
'invenio-jsonschemas>=1.0.0a2',
'isort>=4.2.2',
'jsonpatch>=1.11',
'jsonref>=0.1',
'jsonresolver>=0.1.0',
'jsonschema>=2.5.1',
'mock>=1.0.0',
'pydocstyle>=1.0.0',
'pytest-cache>=1.0',
'pytest-cov>=2.1.0',
'pytest-pep8>=1.0.6',
'pytest>=2.8.0',
]
extras_require = {
'docs': [
'Sphinx>=1.3',
],
'tests': tests_require,
}
extras_require['all'] = []
for name, reqs in extras_require.items():
extras_require['all'].extend(reqs)
setup(
name='cds-dojson',
version=version,
url='http://github.com/CERNDocumentServer/cds-dojson/',
license='BSD',
author='CERN Document Server Team',
author_email='cds-support@cern.ch',
description=__doc__,
long_description=open('README.rst').read(),
packages=['cds_dojson'],
zip_safe=False,
include_package_data=True,
platforms='any',
setup_requires=[
'pytest-runner>=2.6.2',
'setuptools>=17.1',
],
install_requires=[
'arrow>=0.7.0',
'dojson>=1.2.1',
'invenio-query-parser>=0.5.0',
],
extras_require=extras_require,
classifiers=[
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Software Development :: Libraries :: Python Modules',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.5',
'Development Status :: 5 - Production/Stable',
],
tests_require=tests_require,
entry_points={
'cds_dojson.marc21.models': [
'video = cds_dojson.marc21.models.videos.video:model',
'video_project = cds_dojson.marc21.models.videos.project:model'
],
'cds_dojson.marc21.base': [
'base = cds_dojson.marc21.fields.base'
],
'cds_dojson.marc21.video': [
'video = cds_dojson.marc21.fields.videos.video',
'project = cds_dojson.marc21.fields.videos.project'
],
# DoJSON entry points
'console_scripts': [
'cds-dojson=cds_dojson.cli:cli',
],
'dojson.cli.rule': [
'cds_marc21 = cds_dojson.marc21:marc21',
'cds_to_marc21 = cds_dojson.to_marc21:to_marc21'
],
'dojson.cli.load': [
'cds_marcxml = cds_dojson.marc21.utils:load',
],
}
)