diff options
author | Teemu Suo-Anttila <teemusa@vaadin.com> | 2015-07-08 17:17:00 +0300 |
---|---|---|
committer | Teemu Suo-Anttila <teemusa@vaadin.com> | 2015-07-08 17:17:00 +0300 |
commit | 94581505567f09e2fa90f4d41b7fea7cbae1b250 (patch) | |
tree | c6bd2b9bf2d63dabdaa206f1ad27803576d338c1 /scripts/BuildDemos.py | |
parent | 09b8d081fc6a3b4883e2a7837ac077f092fb4aba (diff) | |
download | vaadin-framework-94581505567f09e2fa90f4d41b7fea7cbae1b250.tar.gz vaadin-framework-94581505567f09e2fa90f4d41b7fea7cbae1b250.zip |
Fix version number resolution for validation scripts
Change-Id: I799553cea50cb8e81ab06482f1a971f324da8fa1
Diffstat (limited to 'scripts/BuildDemos.py')
-rw-r--r-- | scripts/BuildDemos.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/scripts/BuildDemos.py b/scripts/BuildDemos.py index 9306153b9a..a13b5ac033 100644 --- a/scripts/BuildDemos.py +++ b/scripts/BuildDemos.py @@ -12,6 +12,7 @@ import sys, os from os.path import join, isfile from fnmatch import fnmatch +from xml.etree.ElementTree import ElementTree # Validated demos. name -> git url demos = { @@ -31,11 +32,11 @@ if __name__ == "__main__": except: print("BuildDemos depends on gitpython. Install it with `pip install gitpython`") sys.exit(1) - from BuildHelpers import updateRepositories, mavenValidate, copyWarFiles, getLogFile, removeDir, getArgs, mavenInstall, resultPath + from BuildHelpers import updateRepositories, mavenValidate, copyWarFiles, getLogFile, removeDir, getArgs, mavenInstall, resultPath, readPomFile from DeployHelpers import deployWar - if hasattr(getArgs(), "artifactPath") and getArgs().artifactPath is not None: + version = False basePath = getArgs().artifactPath poms = [] for root, dirs, files in os.walk(basePath): @@ -48,7 +49,10 @@ if __name__ == "__main__": mavenInstall(pom, jarFile) else: mavenInstall(pom) - + if "vaadin-server" in pom: + pomXml, nameSpace = readPomFile(pom) + for version in pomXml.getroot().findall("./{%s}version" % (nameSpace)): + getArgs().version = version.text demosFailed = False for demo in demos: |