mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-10 22:55:00 +00:00
refactor: Improve version handling and cleanup version-related files
This commit is contained in:
parent
295040c94c
commit
0dbaec553f
5 changed files with 17 additions and 9 deletions
|
@ -4,14 +4,17 @@ __version__ = "0.65.2.dev"
|
|||
safe_version = __version__
|
||||
|
||||
try:
|
||||
from aider.__version__ import __version__
|
||||
from aider._version import __version__
|
||||
except Exception:
|
||||
__version__ = safe_version + ".import"
|
||||
__version__ = safe_version + "+import"
|
||||
|
||||
try:
|
||||
if version.parse(__version__) < version.parse(safe_version):
|
||||
__version__ = safe_version + ".less"
|
||||
except Exception:
|
||||
__version__ = safe_version + ".parse"
|
||||
if type(__version__) is not str:
|
||||
__version__ = safe_version + "+type"
|
||||
else:
|
||||
try:
|
||||
if version.parse(__version__) < version.parse(safe_version):
|
||||
__version__ = safe_version + "+less"
|
||||
except Exception:
|
||||
__version__ = safe_version + "+parse"
|
||||
|
||||
__all__ = [__version__]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue