-
Notifications
You must be signed in to change notification settings - Fork 6
/
setup.py
55 lines (48 loc) · 1.5 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
from __future__ import absolute_import
import os
import sys
try:
from pip._internal.req import parse_requirements
except ImportError:
# pip < 10
from pip.req import parse_requirements
try:
from pip._internal.network.session import PipSession
except ImportError:
try:
from pip._internal.download import PipSession
except ImportError:
# pip < 10
from pip.download import PipSession
from setuptools import find_packages
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
# reading requirements
install_reqs = parse_requirements('requirements.txt', session=PipSession())
try:
requirements = [str(ir.req) for ir in install_reqs]
except AttributeError:
# pip > 20
requirements = [str(ir.requirement) for ir in install_reqs]
sys.path.insert(0, os.path.dirname(__file__))
version = '1.2.3'
setup(
name='cappy',
version=version,
packages=find_packages(),
install_requires=requirements,
license='MIT',
long_description="CAchingProxyinPython is a file based python proxy based on Sharebear's simple python caching proxy",
description='A simple file based python poxy',
keywords=['cappy', 'proxy', 'http'],
url='https://github.com/CompileInc/cappy',
download_url='https://github.com/CompileInc/cappy/archive/v{version}.tar.gz'.format(version=version),
author='Compile Inc',
author_email='[email protected]',
entry_points='''
[console_scripts]
cappy=cappy.cappy:cli
'''
)