From 1ae1650705790b7f533923030023ee857383b9fd Mon Sep 17 00:00:00 2001 From: Sylvain UTARD Date: Wed, 17 Sep 2014 10:02:31 +0200 Subject: [PATCH] Move resources to algoliasearch to work-around this mess... --- algoliasearch/algoliasearch.py | 2 +- {resources => algoliasearch/resources}/ca-bundle.crt | 0 setup.py | 4 ++-- 3 files changed, 3 insertions(+), 3 deletions(-) rename {resources => algoliasearch/resources}/ca-bundle.crt (100%) diff --git a/algoliasearch/algoliasearch.py b/algoliasearch/algoliasearch.py index b19d8059c..638bac04a 100644 --- a/algoliasearch/algoliasearch.py +++ b/algoliasearch/algoliasearch.py @@ -58,7 +58,7 @@ def newFunc(*args, **kwargs): return newFunc -POOL_MANAGER = urllib3.PoolManager(cert_reqs='CERT_REQUIRED', ca_certs=os.path.join(os.path.dirname(__file__), "../resources/ca-bundle.crt")) +POOL_MANAGER = urllib3.PoolManager(cert_reqs='CERT_REQUIRED', ca_certs=os.path.join(os.path.split(__file__)[0], "resources/ca-bundle.crt")) # Exception launched by Algolia Client when an error occured class AlgoliaException(Exception): diff --git a/resources/ca-bundle.crt b/algoliasearch/resources/ca-bundle.crt similarity index 100% rename from resources/ca-bundle.crt rename to algoliasearch/resources/ca-bundle.crt diff --git a/setup.py b/setup.py index 6d818ffc2..9c4874f5f 100644 --- a/setup.py +++ b/setup.py @@ -18,8 +18,8 @@ description='Algolia Search API Client for Python', url='https://github.com/algolia/algoliasearch-client-python', packages = ["algoliasearch"], - package_dir={'': '.'}, - package_data={'': ['resources/*.crt']}, + package_dir={'algoliasearch': 'algoliasearch'}, + package_data={'algoliasearch': ['resources/*.crt']}, include_package_data = True, install_requires = ['urllib3 >= 1.8.2'], keywords = ['algolia', 'pyalgolia', 'search', 'backend', 'hosted', 'cloud', 'full-text search', 'faceted search'],