forked from nix-community/pip2nix
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
82 lines (69 loc) · 2.32 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
from os import path
from setuptools import setup
from setuptools.command.test import test as TestCommand
import sys
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 finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
# import here, cause outside the eggs aren't loaded
import pytest
errno = pytest.main(self.pytest_args)
sys.exit(errno)
here = path.abspath(path.dirname(__file__))
with open(path.join(here, 'README.rst'), 'rb') as f:
long_description = f.read().decode('utf-8')
VERSION = '0.9.0.dev1'
setup(
name="pip2nix",
version=VERSION,
description='Generate Nix expressions for Python packages.',
long_description=long_description,
url="https://github.com/johbo/pip2nix",
author="Tomasz Kontusz",
author_email="[email protected]",
license='GPLv3+',
classifiers=[
'Development Status :: 4 - Beta',
'Intended Audience :: Developers',
'Topic :: Software Development :: Build Tools',
'License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
keywords='nix pip',
install_requires=[
'setuptools',
'pip>=18',
'configobj==5.0.6',
'click',
'contexter',
'jinja2',
'toml',
],
tests_require=['pytest'],
packages=['pip2nix', 'pip2nix.models'],
package_data={'pip2nix': ['*.ini', '*.j2']},
cmdclass={'test': PyTest},
entry_points={
"console_scripts": [
"pip2nix=pip2nix.cli:cli",
"pip2nix%s=pip2nix.cli:cli" % sys.version[:1],
"pip2nix%s=pip2nix.cli:cli" % sys.version[:3],
],
"egg_info.writers": [
"tests_require.txt=pip2nix.egg_writer:write_arg"
]
}
)