-
Notifications
You must be signed in to change notification settings - Fork 7
/
setup.py
68 lines (57 loc) · 2.1 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
#!/usr/bin/env python
import os
import re
import sys
from setuptools import find_packages, setup
_version_re = re.compile(r"__version__\s+=\s+(.*)")
PY_VER = sys.version_info
if PY_VER < (3, 6):
raise RuntimeError("AirSpider doesn't support Python version < 3.6")
def read_version():
regexp = re.compile(r'^__version__\W*=\W*"([\d.abrc]+)"')
init_py = os.path.join(os.path.dirname(__file__), "airspider", "__init__.py")
with open(init_py) as f:
for line in f:
match = regexp.match(line)
if match is not None:
return match.group(1)
def read(file_name):
with open(
os.path.join(os.path.dirname(__file__), file_name), mode="r", encoding="utf-8"
) as f:
return f.read()
setup(
name="AirSpider",
version=read_version(),
author="Liu Xunzhuo",
description="An Easy-to-use and Fast Python Spider Framework",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author_email="mixdeers@gmail.com",
python_requires=">=3.6",
install_requires=["aiohttp>=3.5.4", "cssselect", "lxml"],
url="https://pypi.org/project/airspider/",
packages=find_packages(),
license="MIT",
classifiers=[
"Framework :: AsyncIO",
"Intended Audience :: Developers",
"Development Status :: 4 - Beta",
"License :: OSI Approved :: MIT License",
"Operating System :: POSIX :: Linux",
"Operating System :: MacOS :: MacOS X",
"Operating System :: POSIX :: BSD",
"Operating System :: Microsoft :: Windows",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Software Development :: Libraries :: Application Frameworks",
"Topic :: Software Development :: Libraries :: Python Modules",
],
project_urls={
"Documentation": "https://github.com/xunzhuo/AirSpider",
"Source": "https://github.com/xunzhuo/AirSpider",
},
extras_require={"uvloop": ["uvloop"]},
)