setup.py
This file
Path
setup.py
96 lines · 2.8 KiB · Python
Last changed by
add install_requiresKenneth Reitzbefore adoption1ea27b3
History of this fileTake it
The walk stopped after 200 commits: lines older than 889f855 point at it.
Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
lines 1–11why, one step back1#!/usr/bin/env python23import os4import re5import sys67from codecs import open89from setuptools import setup10from setuptools.command.test import test as TestCommand11Merge branch 'master' of github.com:kennethreitz/requestsKenneth Reitzbefore adoption733ff4b
line 12why, one step back12here = os.path.abspath(os.path.dirname(__file__))Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
lines 13–31why, one step back1314class PyTest(TestCommand):15 user_options = [('pytest-args=', 'a', "Arguments to pass into py.test")]1617 def initialize_options(self):18 TestCommand.initialize_options(self)19 self.pytest_args = []2021 def finalize_options(self):22 TestCommand.finalize_options(self)23 self.test_args = []24 self.test_suite = True2526 def run_tests(self):27 import pytest2829 errno = pytest.main(self.pytest_args)30 sys.exit(errno)31Merge branch 'master' of github.com:kennethreitz/requestsKenneth Reitzbefore adoption733ff4b
line 32why, one step back32# 'setup.py publish' shortcut.Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
line 33why, one step back33if sys.argv[-1] == 'publish':fix setup.pyKenneth Reitzbefore adoption0aee483
lines 34–35why, one step back34 os.system('python setup.py sdist bdist_wheel')35 os.system('twine upload dist/*')Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
lines 36–37why, one step back36 sys.exit()37add install_requiresKenneth Reitzbefore adoption1ea27b3
line 38why, one step back38packages = ['requests']Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
line 39why, one step back39add install_requiresKenneth Reitzbefore adoption1ea27b3
lines 40–45why, one step back40requires = [41 'chardet>=3.0.2,<3.1.0',42 'idna>=2.5,<2.6',43 'urllib3 >=1.21.1,<1.22'4445]Merge pull request #3795 from AdamWill/tests-require-pytest-mockCory Benfieldbefore adoptionedf09ad
line 46why, one step back46test_requirements = ['pytest>=2.8.0', 'pytest-httpbin==0.0.7', 'pytest-cov', 'pytest-mock']Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
line 47why, one step back47Merge branch 'master' of github.com:kennethreitz/requestsKenneth Reitzbefore adoption733ff4b
line 48why, one step back48about = {}__version__.pyKenneth Reitzbefore adoption14d6fa1
line 49why, one step back49with open(os.path.join(here, 'requests', '__version__.py')) as f:Merge branch 'master' of github.com:kennethreitz/requestsKenneth Reitzbefore adoption733ff4b
line 50why, one step back50 exec(f.read(), about)Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
lines 51–57why, one step back5152with open('README.rst', 'r', 'utf-8') as f:53 readme = f.read()54with open('HISTORY.rst', 'r', 'utf-8') as f:55 history = f.read()5657setup(Merge branch 'master' of github.com:kennethreitz/requestsKenneth Reitzbefore adoption733ff4b
lines 58–60why, one step back58 name=about['__title__'],59 version=about['__version__'],60 description=about['__description__'],Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
line 61why, one step back61 long_description=readme + '\n\n' + history,Merge branch 'master' of github.com:kennethreitz/requestsKenneth Reitzbefore adoption733ff4b
lines 62–64why, one step back62 author=about['__author__'],63 author_email=about['__author_email__'],64 url=about['__url__'],Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
lines 65–69why, one step back65 packages=packages,66 package_data={'': ['LICENSE', 'NOTICE'], 'requests': ['*.pem']},67 package_dir={'requests': 'requests'},68 include_package_data=True,69 install_requires=requires,Merge branch 'master' of github.com:kennethreitz/requestsKenneth Reitzbefore adoption733ff4b
line 70why, one step back70 license=about['__license__'],Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
lines 71–83why, one step back71 zip_safe=False,72 classifiers=(73 'Development Status :: 5 - Production/Stable',74 'Intended Audience :: Developers',75 'Natural Language :: English',76 'License :: OSI Approved :: Apache Software License',77 'Programming Language :: Python',78 'Programming Language :: Python :: 2.6',79 'Programming Language :: Python :: 2.7',80 'Programming Language :: Python :: 3',81 'Programming Language :: Python :: 3.3',82 'Programming Language :: Python :: 3.4',83 'Programming Language :: Python :: 3.5',Merge pull request #3801 from andriisoldatenko/add-python-36Kenneth Reitzbefore adoptiona43845e
line 84why, one step back84 'Programming Language :: Python :: 3.6',Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
lines 85–90why, one step back85 'Programming Language :: Python :: Implementation :: CPython',86 'Programming Language :: Python :: Implementation :: PyPy'87 ),88 cmdclass={'test': PyTest},89 tests_require=test_requirements,90 extras_require={Merge pull request #3693 from Lukasa/setuptools-extraCory Benfieldbefore adoption7f2a415
line 91why, one step back91 'security': ['pyOpenSSL>=0.14', 'cryptography>=1.3.4', 'idna>=2.0.0'],Merge pull request #3552 from Trodis/masterIan Cordascobefore adoption39b3477
line 92why, one step back92 'socks': ['PySocks>=1.5.6, !=1.5.7'],Merge pull request #4014 from Lukasa/even-more-compatCory Benfieldbefore adoption2e496c3
line 93why, one step back93 'socks:sys_platform == "win32" and (python_version == "2.7" or python_version == "2.6")': ['win_inet_pton'],Merge pull request #3539 from RichieB2B/ncsc-nl/docufixCory Benfieldbefore adoption889f855
lines 94–95why, one step back94 },95)Merge pull request #3693 from Lukasa/setuptools-extraCory Benfieldbefore adoption7f2a415
line 96why, one step back96