We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 54751d3 commit 2238404Copy full SHA for 2238404
setup.py
@@ -2,9 +2,19 @@
2
# Note that this script only installs the python modules,
3
# the other parts of crmsh are installed by autotools
4
from setuptools import setup
5
+import contextlib
6
+import re
7
+
8
+VERSION = '0.0.1'
9
10
+with contextlib.suppress(Exception):
11
+ with open('version', 'r', encoding='ascii') as f:
12
+ match = re.match('^\\d+\\.\\d+\\.\\d+', f.read().strip())
13
+ if match:
14
+ VERSION = match.group(0)
15
16
setup(name='crmsh',
- version='4.5.0',
17
+ version=VERSION,
18
description='Command-line interface for High-Availability cluster management',
19
author='Kristoffer Gronlund, Xin Liang',
20
author_email='[email protected]',
0 commit comments