source for python-compatible versioning
This commit is contained in:
parent
2e96fcf768
commit
d1af4b031a
|
@ -2,6 +2,7 @@ import setuptools
|
|||
from pathlib import Path
|
||||
import re
|
||||
|
||||
# https://www.python.org/dev/peps/pep-0440
|
||||
with open(Path(__file__).parent/'damask/VERSION') as f:
|
||||
version = re.sub(r'(-([^-]*)).*$',r'.\2',re.sub(r'^v(\d+\.\d+(\.\d+)?)',r'\1',f.readline().strip()))
|
||||
|
||||
|
|
Loading…
Reference in New Issue