From 33075438edf3dcfad77efd9ccc55c121c17bf98a Mon Sep 17 00:00:00 2001 From: Matthias Betz Date: Fri, 12 May 2023 14:09:16 +0200 Subject: [PATCH] changed assemby to execute on install phase --- .../build/plugin/DownloadJreMojo.java | 3 +- .../CityDoctorLocalization.properties | 2 +- CityDoctorParent/CityDoctorValidation/pom.xml | 23 ++++++++--- .../src/assembly/assembly.xml | 38 +++++++++++++++++++ 4 files changed, 59 insertions(+), 7 deletions(-) create mode 100644 CityDoctorParent/CityDoctorValidation/src/assembly/assembly.xml diff --git a/CityDoctorBuildPlugin/src/main/java/de/hft/stuttgart/citydoctor/build/plugin/DownloadJreMojo.java b/CityDoctorBuildPlugin/src/main/java/de/hft/stuttgart/citydoctor/build/plugin/DownloadJreMojo.java index 08fe8b36..ba22003c 100644 --- a/CityDoctorBuildPlugin/src/main/java/de/hft/stuttgart/citydoctor/build/plugin/DownloadJreMojo.java +++ b/CityDoctorBuildPlugin/src/main/java/de/hft/stuttgart/citydoctor/build/plugin/DownloadJreMojo.java @@ -19,7 +19,7 @@ import org.rauschig.jarchivelib.Archiver; import org.rauschig.jarchivelib.ArchiverFactory; import org.rauschig.jarchivelib.CompressionType; -@Mojo(name = "downloadJre", defaultPhase = LifecyclePhase.PREPARE_PACKAGE) +@Mojo(name = "downloadJre", defaultPhase = LifecyclePhase.INSTALL) public class DownloadJreMojo implements org.apache.maven.plugin.Mojo { private Log log; @@ -43,6 +43,7 @@ public class DownloadJreMojo implements org.apache.maven.plugin.Mojo { } outputDir.normalize(); createOutputFolder(outputDir); + log.info("Downloading runtime"); if (url.getFile().endsWith(".tar")) { // handle tar file extractTarFile(outputDir); diff --git a/CityDoctorParent/CityDoctorModel/src/main/resources/CityDoctorLocalization.properties b/CityDoctorParent/CityDoctorModel/src/main/resources/CityDoctorLocalization.properties index 918cef7d..bc37e62a 100644 --- a/CityDoctorParent/CityDoctorModel/src/main/resources/CityDoctorLocalization.properties +++ b/CityDoctorParent/CityDoctorModel/src/main/resources/CityDoctorLocalization.properties @@ -1,4 +1,4 @@ -CityDoctorValidation.Version=@cdVersion@-@gitVersion@ +CityDoctorValidation.Version=${versionString} DistanceError.distanceFromPlane=distance from plane AboutDialog.developedBy=Developed by AboutDialog.contact=Contact diff --git a/CityDoctorParent/CityDoctorValidation/pom.xml b/CityDoctorParent/CityDoctorValidation/pom.xml index c96330e9..d12fccba 100644 --- a/CityDoctorParent/CityDoctorValidation/pom.xml +++ b/CityDoctorParent/CityDoctorValidation/pom.xml @@ -1,6 +1,4 @@ - + 4.0.0 de.hft.stuttgart @@ -75,7 +73,22 @@ org.apache.maven.plugins maven-jar-plugin - 3.2.0 + 3.3.0 + + + de.hft.stuttgart + CityDoctorBuildPlugin + 1.0.0 + + + + downloadJre + + + + + https://download.bell-sw.com/java/17.0.7+7/bellsoft-jre17.0.7+7-windows-amd64.zip + maven-assembly-plugin @@ -89,7 +102,7 @@ create-archive - package + install single diff --git a/CityDoctorParent/CityDoctorValidation/src/assembly/assembly.xml b/CityDoctorParent/CityDoctorValidation/src/assembly/assembly.xml new file mode 100644 index 00000000..95e825cb --- /dev/null +++ b/CityDoctorParent/CityDoctorValidation/src/assembly/assembly.xml @@ -0,0 +1,38 @@ + + zip + + zip + + false + + + libs + + ${project.groupId}:${project.artifactId}:jar:* + + + + + + ${project.build.directory} + / + + ${project.artifactId}-${project.version}.jar + + + + ${project.basedir}/src/assembly + / + + no_runtime/start.bat + common/testConfigWithStreaming.yml + common/REKaiserwall.gml + common/checkForSolid.xml + + true + + + \ No newline at end of file -- GitLab