Skip to content

Commit

Permalink
fix(setup): Fix for setup script
Browse files Browse the repository at this point in the history
  • Loading branch information
Dyl-M committed Aug 18, 2024
1 parent 0bb3aa1 commit 0ce95ef
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,16 @@
"""

import setuptools
import shutil
import subprocess


def get_version_from_git():
"""Retrieve package version from git tag name.
@return: package version.
"""
git_path = shutil.which("git")

if git_path is None:
raise EnvironmentError("Git is not installed or not found in PATH.")

try:
version = (
subprocess.run([git_path, "describe", "--tags"],
subprocess.run(["git", "describe", "--tags"],
check=True,
stdout=subprocess.PIPE).stdout.decode("utf-8").strip()
)
Expand Down

0 comments on commit 0ce95ef

Please sign in to comment.