Commit 48d18f2b authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Update configure_build.py to fix a bug getting plugin version.

parent b2f012e4
......@@ -162,11 +162,9 @@ def get_plugin_version(plugin):
elif plugin == "dbui":
with open(DBUIJS, "rb") as tmpfile:
text = tmpfile.read()
match = re.match(r"(.+ version: ')([\w._-]*)('.+)", text, re.DOTALL)
release = match.group(2)
with open(VERSION, "rb") as tmpfile:
release = tmpfile.read()
release = release.replace(".", "")
elif plugin == "extjs":
......@@ -185,6 +183,10 @@ def get_plugin_version(plugin):
release = match.group(1)
# shrink the release identifier 4.2.1 or 4.2.1.883 -> 421
li = release.split('.')
release = ''.join(li) if len(li) < 4 else ''.join(li[:-1])
elif plugin == "mathjax":
filename = os.path.join('static', 'plugin_mathjax', 'MathJax.js')
......@@ -203,10 +205,6 @@ def get_plugin_version(plugin):
error("\n\tUnknown plugin %" % plugin)
sys.exit(1)
# shrink the release identifier 4.2.1 or 4.2.1.883 -> 421
li = release.split('.')
release = ''.join(li) if len(li) < 4 else ''.join(li[:-1])
if len(release) == 2:
release = "%s0" % release
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment