-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathsetup.py
93 lines (80 loc) · 2.85 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
#! /usr/bin/env python
#
# Copyright (C) 2007-2009 Rich Lewis <[email protected]>
# License: 3-clause BSD
from setuptools.command.test import test as TestCommand
from setuptools import setup, find_packages
import sys
DISTNAME = 'scikit-chem'
DESCRIPTION = 'A set of python modules for cheminformatics'
with open('README.md') as f:
LONG_DESCRIPTION = f.read()
MAINTAINER = 'Richard Lewis'
MAINTAINER_EMAIL = '[email protected]'
URL = 'http://github.com/richlewis42/scikit-chem'
LICENSE = 'new BSD'
DOWNLOAD_URL = 'https://github.com/richlewis42/scikit-chem/archive/master.zip'
CLASSIFIERS = [
'Development Status:: 2 - Pre - Alpha',
'Intended Audience :: Science/Research',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Natural Language :: English',
'Programming Language :: Python',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.5',
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX',
'Operating System :: Unix',
'Operating System :: MacOS',
'Topic :: Software Development',
'Topic :: Scientific/Engineering :: Chemistry'
]
MAJOR = 0
MINOR = 0
MICRO = 6
VERSION = '{major}.{minor}.{micro}'.format(major=MAJOR, minor=MINOR, micro=MICRO)
with open('requirements.txt') as f:
REQUIREMENTS = [l.strip() for l in f]
REQUIREMENTS.remove('rdkit')
with open('test_requirements.txt') as f:
TEST_REQUIREMENTS = [l.strip() for l in f]
class PyTest(TestCommand):
user_options = [('pytest-args=', 'a', "Arguments to pass to py.test")]
def initialize_options(self):
TestCommand.initialize_options(self)
self.pytest_args = []
def run_tests(self):
# import here, cause outside the eggs aren't loaded
import pytest
errno = pytest.main(self.pytest_args)
sys.exit(errno)
def setup_package():
metadata = dict(name=DISTNAME,
maintainer=MAINTAINER,
maintainer_email=MAINTAINER_EMAIL,
description=DESCRIPTION,
license=LICENSE,
url=URL,
version=VERSION,
download_url=DOWNLOAD_URL,
long_description=LONG_DESCRIPTION,
classifiers=CLASSIFIERS
)
setup(
packages=find_packages(),
cmdclass={'test': PyTest},
package_data = {
'skchem.target_prediction': ['data/PIDGIN_models.pkl.gz'],
'skchem.resource': ['atom_data.csv'],
'skchem.standardizers': ['default_config.xml']},
include_package_data=True,
install_requires=REQUIREMENTS,
tests_require=TEST_REQUIREMENTS,
zip_safe=False,
**metadata
)
if __name__ == "__main__":
setup_package()