-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathsetup.py
executable file
·81 lines (71 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
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import re
from setuptools import setup, find_packages
with open('README.md', 'r') as f:
readme = f.read()
version = ''
with open('src/pyright/_version.py') as f:
match = re.search(r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]', f.read(), re.MULTILINE)
if not match:
raise RuntimeError('version is not set')
version = match.group(1)
if not version:
raise RuntimeError('version is not set')
with open('requirements.txt', 'r') as f:
requirements = f.readlines()
extras = {
'dev': [
'twine>=3.4.1',
],
'nodejs': ['nodejs-wheel-binaries'],
}
setup(
name='pyright',
version=version,
author='Robert Craigie',
maintainer='Robert Craigie',
license='MIT',
url='https://github.com/RobertCraigie/pyright-python',
description='Command line wrapper for pyright',
install_requires=requirements,
long_description=readme,
long_description_content_type='text/markdown',
packages=find_packages(
where='src',
include=['pyright', 'pyright.*'],
),
package_dir={'': 'src'},
package_data={'': ['py.typed', 'dist/**']},
python_requires='>=3.7',
include_package_data=True,
zip_safe=False,
entry_points={
'console_scripts': [
'pyright=pyright.cli:entrypoint',
'pyright-python=pyright.cli:entrypoint',
'pyright-langserver=pyright.langserver:entrypoint',
'pyright-python-langserver=pyright.langserver:entrypoint',
],
},
extras_require={
**extras,
'all': [req for requirements in extras.values() for req in requirements],
},
project_urls={
'Source': 'https://github.com/RobertCraigie/pyright-python',
'Tracker': 'https://github.com/RobertCraigie/pyright-python/issues',
},
classifiers=[
'Development Status :: 5 - Production/Stable',
'Intended Audience :: Developers',
'Typing :: Typed',
'Topic :: Software Development :: Libraries :: Python Modules',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
],
)