From 3af5e299a7c80ef5a32e08d75fb74524d42e6975 Mon Sep 17 00:00:00 2001 From: Rongxin Liu Date: Sun, 19 Nov 2023 16:36:49 -0500 Subject: [PATCH] fixed version parsing --- lib50/_api.py | 4 ++-- setup.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib50/_api.py b/lib50/_api.py index b07c2ca..2e6304a 100644 --- a/lib50/_api.py +++ b/lib50/_api.py @@ -660,8 +660,8 @@ def check_dependencies(): raise Error(_("You don't have git. Install git, then re-run!")) # Check that git --version > 2.7 - version = subprocess.check_output(["git", "--version"]).decode("utf-8") - matches = re.search(r"^git version (\d+\.\d+\.\d+).*$", version) + _version = subprocess.check_output(["git", "--version"]).decode("utf-8") + matches = re.search(r"^git version (\d+\.\d+\.\d+).*$", _version) if not matches or version.parse(matches.group(1)) < version.parse("2.7.0"): raise Error(_("You have an old version of git. Install version 2.7 or later, then re-run!")) diff --git a/setup.py b/setup.py index b01c420..60eb5bc 100644 --- a/setup.py +++ b/setup.py @@ -27,6 +27,6 @@ python_requires=">= 3.6", packages=["lib50"], url="https://github.com/cs50/lib50", - version="3.0.9", + version="3.0.10", include_package_data=True )