diff --git a/.bumpversion.cfg b/.bumpversion.cfg new file mode 100644 index 0000000..0a78c46 --- /dev/null +++ b/.bumpversion.cfg @@ -0,0 +1,20 @@ +[bumpversion] +current_version = 1.0.0 +commit = True +tag = False +parse = (?P\d+)\.(?P\d+)\.(?P\d+)(\.(?P[a-z]+)(?P\d+))? +serialize = + {major}.{minor}.{patch} + +[bumpversion:file:setup.py] +search = version='{current_version}' +replace = version='{new_version}' + +[bumpversion:file:redisai/__init__.py] +search = __version__ = '{current_version}' +replace = __version__ = '{new_version}' + +[bumpversion:file:docs/conf.py] +search = release = '{current_version}' +replace = release = '{new_version}' + diff --git a/docs/conf.py b/docs/conf.py index c5018bb..e137356 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,9 +1,7 @@ -import redisai - project = 'redisai-py' copyright = '2020, RedisLabs' author = 'RedisLabs' -release = redisai.__version__ +release = '1.0.0' extensions = ['sphinx.ext.autodoc', 'sphinx.ext.autosummary', 'sphinx.ext.extlinks', diff --git a/redisai/__init__.py b/redisai/__init__.py index 05e5e6c..876a974 100644 --- a/redisai/__init__.py +++ b/redisai/__init__.py @@ -1,2 +1,3 @@ -from .version import __version__ from .client import Client + +__version__ = '1.0.0' diff --git a/redisai/version.py b/redisai/version.py deleted file mode 100644 index 23bc90e..0000000 --- a/redisai/version.py +++ /dev/null @@ -1,5 +0,0 @@ -# Store the version here so: -# 1) we don't load dependencies by storing it in __init__.py -# 2) we can import it in setup.py for the same reason -# 3) we can import it into your module module -__version__ = '0.9.0' diff --git a/setup.py b/setup.py index 6c9a277..f6f651e 100644 --- a/setup.py +++ b/setup.py @@ -1,18 +1,13 @@ #!/usr/bin/env python from setuptools import setup, find_packages -try: - exec(open('redisai/version.py', encoding='utf-8').read()) -except TypeError: - exec(open('redisai/version.py').read()) with open('README.rst') as f: long_description = f.read() - setup( name='redisai', - version=__version__, # comes from redisai/version.py + version='1.0.0', description='RedisAI Python Client', long_description=long_description, long_description_content_type='text/markdown',