Skip to content

Commit

Permalink
Changed version punctuation for PEP 440 compliance
Browse files Browse the repository at this point in the history
They now look like:  0.11.0+295.gec6e264.dirty
instead of:          0.11.0-295-gec6e264-dirty
  • Loading branch information
Kodiologist committed Oct 13, 2016
1 parent ec6e264 commit ac01c0f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,10 @@
PKG = "hy"
VERSIONFILE = os.path.join(PKG, "version.py")
try:
__version__ = subprocess.check_output([
"git", "describe", "--tags", "--dirty"]).decode('ASCII').strip()
__version__ = (subprocess.check_output
(["git", "describe", "--tags", "--dirty"])
.decode('ASCII').strip()
.replace('-', '+', 1).replace('-', '.'))
with open(VERSIONFILE, "wt") as o:
o.write("__version__ = {!r}\n".format(__version__))
except subprocess.CalledProcessError:
Expand Down

0 comments on commit ac01c0f

Please sign in to comment.