Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding script to generate nightly resources.
- Loading branch information
BugDiver
committed
Oct 16, 2018
1 parent
57c4f2f
commit 04b76a9
Showing
1 changed file
with
15 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
from datetime import datetime | ||
from xml.dom import minidom | ||
from subprocess import call | ||
|
||
pom_file_name = 'pom.xml' | ||
pom = minidom.parse(pom_file_name) | ||
childs = pom.getElementsByTagName('version') | ||
version = childs[0].firstChild | ||
version.data = "{0}-nightly-{1}".format(version.data, datetime.today().strftime('%Y-%m-%d')) | ||
pom_file = open(pom_file_name, 'w') | ||
pom_file.write(pom.saveXML(None).replace('<?xml version="1.0" ?>', '')) | ||
pom_file.close() | ||
|
||
call(['mvn', 'package']) | ||
call(['mvn', '-Doutput=pom.xml', 'help:effective-pom']) |