diff --git a/scripts/versionbump.py b/scripts/versionbump.py index 027e15658..67e1a0b2f 100644 --- a/scripts/versionbump.py +++ b/scripts/versionbump.py @@ -19,12 +19,14 @@ def main(): raise ValueError(f"Invalid version format, must be x.y.z: {new_version_str}") new_version = version.parse(new_version_str) - incremented_version = version.Version(f"{new_version.major}.{new_version.minor}.{new_version.micro + 1}") + incremented_version = version.Version( + f"{new_version.major}.{new_version.minor}.{new_version.micro + 1}" + ) with open("aider/__init__.py", "r") as f: content = f.read() - current_version = re.search(r'__version__ = "(.+?)"', content).group(1).split("-dev")[0] + current_version = re.search(r'__version__ = "(.+?)"', content).group(1) if new_version <= version.parse(current_version): raise ValueError( f"New version {new_version} must be greater than the current version {current_version}"