forked from sensiblecodeio/scraperwiki-python
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
executable file
·48 lines (40 loc) · 1.41 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
#!/usr/bin/env python2
# This file is part of Local Scraperlibs.
import warnings
import os
from distutils.core import setup
def has_external_dependency(name):
'Check that a non-Python dependency is installed.'
for directory in os.environ['PATH'].split(':'):
if os.path.exists(os.path.join(directory, name)):
return True
return False
if not has_external_dependency('pdftohtml'):
warnings.warn(
'scraperwiki.pdftoxml requires pdftohtml, but pdftohtml was not found\n'
'in the PATH. If you wish to use this function, you probably need to\n'
'install pdftohtml.'
)
config = dict(name='scraperwiki',
author='Francis Irving',
author_email='[email protected]',
description='Local version of ScraperWiki libraries',
url='https://github.com/scraperwiki/scraperwiki-python',
classifiers=[
'Intended Audience :: Developers',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)',
'Programming Language :: Python :: 2.7',
'Programming Language :: SQL',
'Topic :: Database :: Front-Ends',
],
packages=['scraperwiki', 'scraperwiki.runlog'],
version = '0.3.10',
license='GPL',
)
try:
from setuptools import setup
config['install_requires'] = ['dumptruck>=0.1.6', 'requests'],
except ImportError:
pass
setup(**config)