Skip to content

Commit

Permalink
Cosmetic changes to setup.py
Browse files Browse the repository at this point in the history
  • Loading branch information
ghislainv committed Jun 9, 2024
1 parent e91c5ee commit 359dc99
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,17 @@


# find_version
def find_version():
def find_version(pkg_name):
"""Finding package version."""
with open("pywdpa/__init__.py", encoding="utf-8") as init_file:
with open(f"{pkg_name}/__init__.py", encoding="utf-8") as init_file:
init_text = init_file.read()
_version = (re.search('^__version__\\s*=\\s*"(.*)"',
init_text, re.M)
.group(1))
return _version


version = find_version()
version = find_version("pywdpa")

# reStructuredText README file
with io.open("README.rst", encoding="utf-8") as f:
Expand Down

0 comments on commit 359dc99

Please sign in to comment.