You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by rz...@apache.org on 2021/12/21 13:12:56 UTC

[tomee] 01/02: TOMEE-3000 - Make sure BOMs are auto-generated during the build so we just need to compare and push if needed. This might be an issue during a release process if git detects changes but we'll see when it comes

This is an automated email from the ASF dual-hosted git repository.

rzo1 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomee.git

commit 7b1f8baef12bf2503ce6ccbc0e94900b20b4630e
Author: Richard Zowalla <rz...@apache.org>
AuthorDate: Tue Dec 21 13:39:56 2021 +0100

    TOMEE-3000 - Make sure BOMs are auto-generated during the build so we just need to compare and push if needed. This might be an issue during a release process if git detects changes but we'll see when it comes
---
 tomee/apache-tomee/pom.xml                         | 53 +++++++++++++++++++++-
 .../org/apache/tomee/bootstrap/GenerateBoms.java   |  2 +-
 .../src/test/resources/api-pom-template.xml        |  0
 .../src/test/resources/pom-template.xml            |  0
 tomee/tomee-bootstrap/pom.xml                      | 35 --------------
 5 files changed, 53 insertions(+), 37 deletions(-)

diff --git a/tomee/apache-tomee/pom.xml b/tomee/apache-tomee/pom.xml
index 67de3af..b66bbc1 100644
--- a/tomee/apache-tomee/pom.xml
+++ b/tomee/apache-tomee/pom.xml
@@ -144,6 +144,14 @@
       <version>${tomcat.version}</version>
       <scope>provided</scope>
     </dependency>
+
+    <!-- needed for BOM generation -->
+    <dependency>
+      <groupId>org.projectlombok</groupId>
+      <artifactId>lombok</artifactId>
+      <version>1.18.20</version>
+      <scope>test</scope>
+    </dependency>
   </dependencies>
 
   <build>
@@ -157,7 +165,12 @@
         <filtering>false</filtering>
       </resource>
     </resources>
-
+    <testResources>
+      <testResource>
+        <directory>src/test/resources</directory>
+        <filtering>true</filtering>
+      </testResource>
+    </testResources>
   </build>
 
   <profiles>
@@ -562,6 +575,25 @@
               </execution>
             </executions>
           </plugin>
+          <plugin>
+            <groupId>org.codehaus.mojo</groupId>
+            <artifactId>exec-maven-plugin</artifactId>
+            <version>3.0.0</version>
+            <executions>
+              <execution>
+                <phase>package</phase>
+                <goals>
+                  <goal>java</goal>
+                </goals>
+              </execution>
+            </executions>
+            <configuration>
+              <includeProjectDependencies>true</includeProjectDependencies>
+              <includePluginDependencies>false</includePluginDependencies>
+              <classpathScope>test</classpathScope>
+              <mainClass>org.apache.tomee.bootstrap.GenerateBoms</mainClass>
+            </configuration>
+          </plugin>
         </plugins>
       </build>
     </profile>
@@ -772,6 +804,25 @@
               </execution>
             </executions>
           </plugin>
+          <plugin>
+            <groupId>org.codehaus.mojo</groupId>
+            <artifactId>exec-maven-plugin</artifactId>
+            <version>3.0.0</version>
+            <executions>
+              <execution>
+                <phase>package</phase>
+                <goals>
+                  <goal>java</goal>
+                </goals>
+              </execution>
+            </executions>
+            <configuration>
+              <includeProjectDependencies>true</includeProjectDependencies>
+              <includePluginDependencies>false</includePluginDependencies>
+              <classpathScope>test</classpathScope>
+              <mainClass>org.apache.tomee.bootstrap.GenerateBoms</mainClass>
+            </configuration>
+          </plugin>
         </plugins>
       </build>
     </profile>
diff --git a/tomee/tomee-bootstrap/src/test/java/org/apache/tomee/bootstrap/GenerateBoms.java b/tomee/apache-tomee/src/test/java/org/apache/tomee/bootstrap/GenerateBoms.java
similarity index 99%
rename from tomee/tomee-bootstrap/src/test/java/org/apache/tomee/bootstrap/GenerateBoms.java
rename to tomee/apache-tomee/src/test/java/org/apache/tomee/bootstrap/GenerateBoms.java
index 4941539..727db63 100644
--- a/tomee/tomee-bootstrap/src/test/java/org/apache/tomee/bootstrap/GenerateBoms.java
+++ b/tomee/apache-tomee/src/test/java/org/apache/tomee/bootstrap/GenerateBoms.java
@@ -69,7 +69,7 @@ public class GenerateBoms {
     public GenerateBoms() {
         /*
          * Resolve all project paths relative to this built class
-         * that lives in `tomee/tomee-bootstrap/target/test-classes/`
+         * that lives in `tomee/apache-tomee/target/test-classes/`
          *
          * We walk backwards from that directory till we find the
          * project root and then we can build all relative paths
diff --git a/tomee/tomee-bootstrap/src/test/resources/api-pom-template.xml b/tomee/apache-tomee/src/test/resources/api-pom-template.xml
similarity index 100%
rename from tomee/tomee-bootstrap/src/test/resources/api-pom-template.xml
rename to tomee/apache-tomee/src/test/resources/api-pom-template.xml
diff --git a/tomee/tomee-bootstrap/src/test/resources/pom-template.xml b/tomee/apache-tomee/src/test/resources/pom-template.xml
similarity index 100%
rename from tomee/tomee-bootstrap/src/test/resources/pom-template.xml
rename to tomee/apache-tomee/src/test/resources/pom-template.xml
diff --git a/tomee/tomee-bootstrap/pom.xml b/tomee/tomee-bootstrap/pom.xml
index 825bde3..5c5cfb9 100644
--- a/tomee/tomee-bootstrap/pom.xml
+++ b/tomee/tomee-bootstrap/pom.xml
@@ -36,35 +36,6 @@
     <tomee.build.name>${project.groupId}.tomee.catalina</tomee.build.name>
   </properties>
 
-  <build>
-    <testResources>
-      <testResource>
-        <directory>src/test/resources</directory>
-        <filtering>true</filtering>
-      </testResource>
-    </testResources>
-    <plugins>
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>exec-maven-plugin</artifactId>
-        <version>3.0.0</version>
-        <executions>
-          <execution>
-            <!--<phase>package</phase>-->
-            <goals>
-              <goal>java</goal>
-            </goals>
-          </execution>
-        </executions>
-        <configuration>
-          <includeProjectDependencies>true</includeProjectDependencies>
-          <includePluginDependencies>false</includePluginDependencies>
-          <classpathScope>test</classpathScope>
-          <mainClass>org.apache.tomee.bootstrap.GenerateBoms</mainClass>
-        </configuration>
-      </plugin>
-    </plugins>
-  </build>
   <dependencies>
     <dependency>
       <groupId>org.apache.tomcat</groupId>
@@ -93,12 +64,6 @@
       <artifactId>openejb-core</artifactId>
       <version>${project.version}</version>
     </dependency>
-    <dependency>
-      <groupId>org.projectlombok</groupId>
-      <artifactId>lombok</artifactId>
-      <version>1.18.20</version>
-      <scope>test</scope>
-    </dependency>
   </dependencies>
 </project>