from setuptools import setup, find_packages

from hdx.utilities.path import script_dir_plus_file

requirements = ['ckanapi',
                'colorlog',
                'ndg-httpsclient',
                'pyasn1',
                'pyOpenSSL',
                'pyaml',
                'requests',
                'scraperwiki',
                'typing'
                ]

version_file = open(script_dir_plus_file('version.txt', requirements))
version = version_file.read().strip()

setup(
    name='hdx-python-api',
    version=version,
    packages=find_packages(exclude=['ez_setup', 'tests', 'tests.*']),
    url='http://data.humdata.org/',
    license='PSF',
    author='Michael Rans',
    author_email='rans@email.com',
    description='HDX Python Library',

    install_requires=requirements,
    package_data={
        # If any package contains *.yml files, include them:
        '': ['*.yml'],
    },
)

from setuptools import setup, find_packages

from hdx.utilities.path import script_dir_plus_file


def get_version():
    version_file = open(script_dir_plus_file('version.txt', get_version))
    return version_file.read().strip()

requirements = ['ckanapi',
                'colorlog',
                'ndg-httpsclient',
                'pyasn1',
                'pyOpenSSL',
                'pyaml',
                'requests',
                'scraperwiki',
                'typing'
                ]

setup(
    name='hdx-python-api',
    version=get_version(),
    packages=find_packages(exclude=['ez_setup', 'tests', 'tests.*']),
    url='http://data.humdata.org/',
    license='PSF',
    author='Michael Rans',
    author_email='rans@email.com',
    description='HDX Python Library',

    install_requires=requirements,
    package_data={
        # If any package contains *.yml files, include them:
        '': ['*.yml'],
    },
)

Make download work using url filename Add user agent string