setup.py
This file
Path
setup.py
63 lines · 1.6 KiB · Python
Last changed by
packagingKenneth Reitzbefore adoption082f4d8
History of this fileTake it
easy setup.pyKenneth Reitzbefore adoption0477018
lines 1–5why, one step back1#!/usr/bin/env python2# -*- coding: utf-8 -*-34import os5import sysMerge branch 'release/0.2.4'Kenneth Reitzbefore adoptiond2cdefa
line 6why, one step back6import requestseasy setup.pyKenneth Reitzbefore adoption0477018
line 7why, one step back7Merge branch 'release/0.5.0'Kenneth Reitzbefore adoption2d98ca7
lines 8–11why, one step back8try:9 from setuptools import setup10except ImportError:11 from distutils.core import setupeasy setup.pyKenneth Reitzbefore adoption0477018
lines 12–13why, one step back1213Merge branch 'release/0.3.2'Kenneth Reitzbefore adoption642c667
line 14why, one step back14Merge branch 'develop'Kenneth Reitzbefore adoption8c1fd5d
lines 15–16why, one step back15if sys.argv[-1] == 'publish':16 os.system('python setup.py sdist upload')Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
line 17why, one step back17 sys.exit()easy setup.pyKenneth Reitzbefore adoption0477018
line 18why, one step back18Merge branch 'develop'Kenneth Reitzbefore adoption8c1fd5d
lines 19–20why, one step back19if sys.argv[-1] == 'test':20 os.system('python test_requests.py')Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
line 21why, one step back21 sys.exit()Merge branch 'release/0.3.2'Kenneth Reitzbefore adoption642c667
line 22why, one step back22certifiKenneth Reitzbefore adoption31d495f
line 23why, one step back23required = [certifi v0.0.4Kenneth Reitzbefore adoption5f768b1
line 24why, one step back24 'certifi>=0.0.4'certifiKenneth Reitzbefore adoption31d495f
line 25why, one step back25]easy setup.pyKenneth Reitzbefore adoption0477018
line 26why, one step back26Merge branch 'release/0.3.2'Kenneth Reitzbefore adoption642c667
lines 27–28why, one step back27if sys.version_info[:2] < (2,6):28 required.append('simplejson')easy setup.pyKenneth Reitzbefore adoption0477018
lines 29–30why, one step back2930setup(Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
line 31why, one step back31 name='requests',Merge branch 'release/0.2.4'Kenneth Reitzbefore adoptiond2cdefa
line 32why, one step back32 version=requests.__version__,Merge branch 'release/0.5.1'Kenneth Reitzbefore adoption95ba6fc
line 33why, one step back33 description='Python HTTP for Humans.',Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
lines 34–37why, one step back34 long_description=open('README.rst').read() + '\n\n' +35 open('HISTORY.rst').read(),36 author='Kenneth Reitz',37 author_email='me@kennethreitz.com',Merge branch 'release/0.4.1'Kenneth Reitzbefore adoptionadd6fea
line 38why, one step back38 url='http://python-requests.org',Merge branch 'develop'Kenneth Reitzbefore adoption8c1fd5d
line 39why, one step back39 packages=[Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
lines 40–41why, one step back40 'requests',41 'requests.packages',Merge branch 'develop'Kenneth Reitzbefore adoptiond1dfa02
line 42why, one step back42 'requests.packages.urllib3',packagingKenneth Reitzbefore adoption082f4d8
line 43why, one step back43 'requests.packages.urllib3.packages',ssl hostnameKenneth Reitzbefore adoptioncfb1a47
line 44why, one step back44 'requests.packages.urllib3.packages.ssl_match_hostname',Merge branch 'develop'Kenneth Reitzbefore adoptiond1dfa02
line 45why, one step back45 'requests.packages.oreos'Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
line 46why, one step back46 ],Merge branch 'develop'Kenneth Reitzbefore adoption8c1fd5d
lines 47–48why, one step back47 package_data={'': ['LICENSE', 'NOTICE']},48 include_package_data=True,Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
lines 49–51why, one step back49 install_requires=required,50 license='ISC',51 classifiers=(Merge branch 'release/0.2.4'Kenneth Reitzbefore adoptiond2cdefa
line 52why, one step back52 'Development Status :: 5 - Production/Stable',Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
lines 53–56why, one step back53 'Intended Audience :: Developers',54 'Natural Language :: English',55 'License :: OSI Approved :: ISC License (ISCL)',56 'Programming Language :: Python',Merge branch 'release/0.2.4'Kenneth Reitzbefore adoptiond2cdefa
line 57why, one step back57 'Programming Language :: Python :: 2.5',easy setup.pyKenneth Reitzbefore adoption0477018
line 58why, one step back58 'Programming Language :: Python :: 2.6',Merge branch 'release/0.9.4'Kenneth Reitzbefore adoption952970f
lines 59–62why, one step back59 'Programming Language :: Python :: 2.7',60 # 'Programming Language :: Python :: 3.0',61 # 'Programming Language :: Python :: 3.1',62 ),easy setup.pyKenneth Reitzbefore adoption0477018
line 63why, one step back63)