Remove python3-memcached.

Use python-memcached instead since it now supports python 2 and
python 3.
This commit is contained in:
Dave Shawley 2018-01-09 14:01:54 -05:00
parent e6b345a1e7
commit ed51012ee1
6 changed files with 19 additions and 11 deletions

View file

@ -1,2 +1,5 @@
include LICENSE include LICENSE
include README.rst include requirements.txt
include test-requirements.txt
include dev-requirements.txt
include tests.py

View file

@ -1,4 +1,7 @@
Version History Version History
--------------- ---------------
- Next Release
- Remove usage of python3-memcached since python-memcached supports
both Python2 & Python3
- 1.0.0 [2014-09-03] - 1.0.0 [2014-09-03]
- Initial release - Initial release

1
requirements.txt Normal file
View file

@ -0,0 +1 @@
python-memcached>=1.59,<2

View file

@ -1 +0,0 @@
python-memcached

View file

@ -1 +0,0 @@
python3-memcached

View file

@ -3,12 +3,15 @@ import sys
import setuptools import setuptools
install_requires = ['sprockets']
if sys.version_info < (3, 0): def read_requirements(name):
install_requires.append('python-memcached') requirements = []
if sys.version_info >= (3, 0): with open(name) as req_file:
install_requires.append('python3-memcached') for line in req_file:
if '#' in line:
line = line[:line.index('#')]
requirements.append(line.strip())
return requirements
setuptools.setup( setuptools.setup(
@ -44,7 +47,7 @@ setuptools.setup(
'sprockets.clients.memcached'], 'sprockets.clients.memcached'],
package_data={'': ['LICENSE', 'README.rst']}, package_data={'': ['LICENSE', 'README.rst']},
include_package_data=True, include_package_data=True,
namespace_packages=['sprockets', namespace_packages=['sprockets', 'sprockets.clients'],
'sprockets.clients'], install_requires=read_requirements('requirements.txt'),
install_requires=install_requires, tests_require=read_requirements('test-requirements.txt'),
zip_safe=False) zip_safe=False)