Skip to content

Commit

Permalink
Do not use the spec release for the pip version
Browse files Browse the repository at this point in the history
The spec release field is to be used only for spec file
adjustments without changes of the code itself.
  • Loading branch information
psss committed Jun 9, 2022
1 parent 911b114 commit 7724ec1
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,13 @@
with open("README") as readme:
long_description = readme.read()

# Parse version and release from master spec file
# Parse version from the spec file
with open("python-nitrate.spec") as specfile:
lines = "\n".join(line.rstrip() for line in specfile)
version = re.search('Version: (.+)', lines).group(1).rstrip()
release = re.search('Release: (\d+)', lines).group(1).rstrip()

setup(name='nitrate',
version='{0}'.format('.'.join([version, release])),
version=version,
packages=['nitrate'],
package_dir={'nitrate': 'source'},
scripts=['source/nitrate'],
Expand Down

0 comments on commit 7724ec1

Please sign in to comment.