From 573eb09f74b4698c5c7fb526d5c79de05f2818fd Mon Sep 17 00:00:00 2001 From: Azalea Gui Date: Thu, 23 Mar 2023 21:23:40 -0400 Subject: [PATCH] [F] Fix reading version requires typing dependency --- hyfetch/__version__.py | 1 + hyfetch/constants.py | 2 +- setup.py | 4 ++-- 3 files changed, 4 insertions(+), 3 deletions(-) create mode 100644 hyfetch/__version__.py diff --git a/hyfetch/__version__.py b/hyfetch/__version__.py new file mode 100644 index 00000000..1d65e978 --- /dev/null +++ b/hyfetch/__version__.py @@ -0,0 +1 @@ +VERSION = '1.4.7' diff --git a/hyfetch/constants.py b/hyfetch/constants.py index f6b0c668..1d8be42f 100644 --- a/hyfetch/constants.py +++ b/hyfetch/constants.py @@ -5,9 +5,9 @@ from dataclasses import dataclass from pathlib import Path from .types import LightDark +from .__version__ import VERSION CONFIG_PATH = Path.home() / '.config/hyfetch.json' -VERSION = '1.4.7' TEST_ASCII = r""" diff --git a/setup.py b/setup.py index c6bb56da..70f4bd77 100755 --- a/setup.py +++ b/setup.py @@ -3,7 +3,7 @@ import pathlib from setuptools import setup, find_namespace_packages -import hyfetch.constants +from hyfetch.__version__ import VERSION # The directory containing this file HERE = pathlib.Path(__file__).parent @@ -14,7 +14,7 @@ README = (HERE / "README.md").read_text('utf-8') # This call to setup() does all the work setup( name="HyFetch", - version=hyfetch.constants.VERSION, + version=VERSION, description="neofetch with flags <3", long_description=README, long_description_content_type="text/markdown",