Skip to content
Snippets Groups Projects
Commit 87fa0c5b authored by dgelessus's avatar dgelessus
Browse files

Add category.xml to Git instead of generating it

Now that the version numbers no longer need to change, there's no need
to generate this file dynamically anymore.
parent c0249758
No related branches found
No related tags found
No related merge requests found
Pipeline #131236 passed
...@@ -10,4 +10,3 @@ updatesite/ ...@@ -10,4 +10,3 @@ updatesite/
**/lib/dependencies/ **/lib/dependencies/
de.prob.core/prob/ de.prob.core/prob/
build/ build/
de.prob.repository/category.xml
\ No newline at end of file
...@@ -10,21 +10,6 @@ project.ext { ...@@ -10,21 +10,6 @@ project.ext {
] ]
groupID = "de.prob" groupID = "de.prob"
categoryId = "de.prob2.feature.category"
categoryLabel = "ProB for Rodin"
// When editing the description here,
// also update the descriptions in all feature.xml files!
categoryDescription = """\
ProB is an animator and model checker for the B-Method. It allows
fully automatic animation of many B specifications, and can be
used to systematically check a specification for errors.
Part of the research and development was conducted within the
EPSRC funded projects ABCD and iMoc, and within the EU funded
projects Rodin and Deploy and the DFG projects Gepavas and Gepavas II.
ProB has been successfully used on various industrial specifications
and is now being used e.g. within Siemens, Alstom, Thales and ClearSy.
""".stripIndent()
} }
apply from: 'tycho_build.gradle' apply from: 'tycho_build.gradle'
......
<?xml version="1.0" encoding="UTF-8"?>
<site>
<feature id="de.prob2.disprover.feature" version="0.0.0">
<category name="de.prob2.feature.category"/>
</feature>
<feature id="de.prob2.feature" version="0.0.0">
<category name="de.prob2.feature.category"/>
</feature>
<feature id="de.prob2.symbolic.feature" version="0.0.0">
<category name="de.prob2.feature.category"/>
</feature>
<category-def name="de.prob2.feature.category" label="ProB for Rodin">
<description>
ProB is an animator and model checker for the B-Method. It allows
fully automatic animation of many B specifications, and can be
used to systematically check a specification for errors.
Part of the research and development was conducted within the
EPSRC funded projects ABCD and iMoc, and within the EU funded
projects Rodin and Deploy and the DFG projects Gepavas and Gepavas II.
ProB has been successfully used on various industrial specifications
and is now being used e.g. within Siemens, Alstom, Thales and ClearSy.
</description>
</category-def>
</site>
...@@ -370,27 +370,7 @@ clean.dependsOn(deleteParent) ...@@ -370,27 +370,7 @@ clean.dependsOn(deleteParent)
// define Repository // define Repository
task createRepository() { task createRepository() {
doLast{ doLast{
new File(workspacePath + "${repositoryName}").mkdir() def pom = new File(workspacePath + repositoryName + '/pom.xml')
String versionNumber = '1.0.0.qualifier'
String artifactId = repositoryName
String featureArtifactId
def f = new File(workspacePath + artifactId + '/category.xml')
f.delete()
f << categoryHead()
for (int i = 0; i < features.size(); i++) {
def parsedXml = new XmlParser().parse("${workspacePath}${features[i]}/feature.xml")
featureArtifactId = parsedXml.attribute("id")
f << categoryFeature(categoryId, featureArtifactId.replace(workspacePath, ''))
}
f << categoryDef(categoryId, categoryLabel, categoryDescription)
f << categoryEnd()
def pom = new File(workspacePath + artifactId + '/pom.xml')
pom.delete() pom.delete()
pom << reposi() pom << reposi()
} }
...@@ -565,31 +545,6 @@ def reposi() {"""\ ...@@ -565,31 +545,6 @@ def reposi() {"""\
</project> </project>
"""} """}
// creates a category in
def categoryHead() {"""\
<?xml version="1.0" encoding="UTF-8"?>
<site>
"""}
def categoryFeature(category, artifactId) {"""
<feature id="${artifactId}" version="0.0.0">
<category name="${category}"/>
</feature>
"""}
def categoryDef(id, label, categorydescription) {"""
<category-def name="${id}" label="${label}">
<description>
${categorydescription}
</description>
</category-def>
"""}
def categoryEnd() {"""
</site>
"""}
// end of category definition
// feature pom // feature pom
def feature(artifactId, versionNumber) {"""\ def feature(artifactId, versionNumber) {"""\
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment