-
Notifications
You must be signed in to change notification settings - Fork 3
/
setup.py
74 lines (64 loc) · 2.19 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
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (C) 2016-2017 mosquito <sensor.wen@gmail.com>
# Use of this source code is governed by MIT license that can be found
# in the LICENSE file.
from setuptools import setup, find_packages
from setuptools.command.test import test as TestCommand
import sys
import re
import checker
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = ['-v']
self.test_suite = True
def run_tests(self):
import pytest
err_code = pytest.main(self.test_args)
sys.exit(err_code)
with open('requirements.txt', 'r') as f:
install_deps = re.split("==.*\n", f.read())[0:-1]
setup(
name=checker.__pkgname__,
version=checker.__version__,
license=checker.__license__,
url=checker.__url__,
author=checker.__author__,
author_email=checker.__email__,
description=checker.__descript__,
long_description=open('README.rst').read(),
packages=find_packages(exclude=['tests']),
include_package_data=True,
platforms='any',
install_requires=install_deps,
entry_points={
'console_scripts': [
'checker = checker:main'
],
},
test_suite="tests",
tests_require=['pytest'],
cmdclass={'test': PyTest},
keywords=['network', 'checker', 'gui'],
# https://pypi.python.org/pypi?%3Aaction=list_classifiers
classifiers=[
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Environment :: X11 Applications :: Qt',
'License :: OSI Approved :: MIT License',
'Natural Language :: Chinese (Simplified)',
'Natural Language :: Chinese (Traditional)',
'Natural Language :: English',
'Operating System :: POSIX :: Linux',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Topic :: Utilities'
]
)