mirror of
https://github.com/aljazceru/dev-gpt.git
synced 2025-12-21 07:34:20 +01:00
💚 fix: fix version in setup.py
This commit is contained in:
15
setup.py
15
setup.py
@@ -1,3 +1,5 @@
|
|||||||
|
from os import path
|
||||||
|
|
||||||
from setuptools import setup, find_packages
|
from setuptools import setup, find_packages
|
||||||
|
|
||||||
def read_requirements():
|
def read_requirements():
|
||||||
@@ -5,9 +7,20 @@ def read_requirements():
|
|||||||
return [line.strip() for line in f.readlines() if not line.startswith('#')]
|
return [line.strip() for line in f.readlines() if not line.startswith('#')]
|
||||||
|
|
||||||
|
|
||||||
|
try:
|
||||||
|
libinfo_py = path.join('src', '__init__.py')
|
||||||
|
libinfo_content = open(libinfo_py, 'r', encoding='utf8').readlines()
|
||||||
|
version_line = [l.strip() for l in libinfo_content if l.startswith('__version__')][
|
||||||
|
0
|
||||||
|
]
|
||||||
|
exec(version_line) # gives __version__
|
||||||
|
except FileNotFoundError:
|
||||||
|
__version__ = '0.0.0'
|
||||||
|
|
||||||
|
|
||||||
setup(
|
setup(
|
||||||
name='gptdeploy',
|
name='gptdeploy',
|
||||||
version='0.18.27',
|
version=__version__,
|
||||||
description='Use natural language interface to generate, deploy and update your microservice infrastructure.',
|
description='Use natural language interface to generate, deploy and update your microservice infrastructure.',
|
||||||
long_description=open('README.md', 'r', encoding='utf-8').read(),
|
long_description=open('README.md', 'r', encoding='utf-8').read(),
|
||||||
long_description_content_type='text/markdown',
|
long_description_content_type='text/markdown',
|
||||||
|
|||||||
Reference in New Issue
Block a user