1+ import re
2+ from os import path
3+ from setuptools import setup
4+
5+
6+ def read (* parts ):
7+ filename = path .join (path .dirname (__file__ ), * parts )
8+ with open (filename ) as fp :
9+ return fp .read ()
10+
11+
12+ def find_version (* file_paths ):
13+ version_file = read (* file_paths )
14+ version_match = re .search (r"^__version__ = ['\"]([^'\"]*)['\"]" ,
15+ version_file , re .M )
16+ if version_match :
17+ return version_match .group (1 )
18+ raise RuntimeError ("Unable to find version string." )
19+
20+
21+ DESCRIPTION = "Tiny REST API Client for intercom.io"
22+
23+ LONG_DESCRIPTION = None
24+ try :
25+ LONG_DESCRIPTION = open ('README.md' ).read ()
26+ except :
27+ pass
28+
29+ CLASSIFIERS = [
30+ 'Development Status :: 4 - Beta' ,
31+ 'Intended Audience :: Developers' ,
32+ 'License :: OSI Approved :: MIT License' ,
33+ 'Operating System :: OS Independent' ,
34+ 'Programming Language :: Python' ,
35+ 'Programming Language :: Python :: 3.5' ,
36+ 'Programming Language :: Python :: 3.6' ,
37+ 'Topic :: Software Development :: Libraries :: Python Modules' ,
38+ ]
39+
40+ setup (
41+ name = 'intercomic' ,
42+ version = find_version ("intercomic" , "__init__.py" ),
43+ description = DESCRIPTION ,
44+ long_description = LONG_DESCRIPTION ,
45+ classifiers = CLASSIFIERS ,
46+ keywords = "intercom, api" ,
47+ author = 'Dmitrii Gerasimenko' ,
48+ 49+ url = 'http://github.com/kidig/intercomic' ,
50+ license = 'MIT' ,
51+ packages = ['intercomic' ],
52+ install_requires = [
53+ "requests"
54+ ],
55+ include_package_data = True ,
56+ zip_safe = False ,
57+ )
0 commit comments