You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by GitBox <gi...@apache.org> on 2022/12/31 15:50:36 UTC

[GitHub] [maven] hboutemy opened a new pull request, #944: [MNG-7652] swtich to Modello Velocity

hboutemy opened a new pull request, #944:
URL: https://github.com/apache/maven/pull/944

   https://issues.apache.org/jira/browse/MNG-7652


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] hboutemy commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
hboutemy commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060324331


##########
api/pom.xml:
##########
@@ -45,6 +44,27 @@
     <project.directory>api</project.directory>
   </properties>
 
+  <build>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <groupId>org.codehaus.modello</groupId>
+          <artifactId>modello-maven-plugin</artifactId>
+          <executions>
+            <execution>
+              <id>modello-site-docs</id>
+              <goals>
+                <goal>xdoc</goal>
+                <goal>xsd</goal>
+              </goals>
+              <phase>none</phase>

Review Comment:
   yes: it "disables" the execution that is enabled by default, ie. bound to real existing lifecycles



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] gnodet commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
gnodet commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060060788


##########
api/maven-api-model/pom.xml:
##########
@@ -63,26 +63,26 @@ under the License.
         </executions>
       </plugin>
       <plugin>
-        <groupId>org.apache.maven</groupId>
-        <artifactId>modello-plugin-velocity</artifactId>
-        <configuration>
-          <version>4.2.0</version>
-          <models>
-            <model>src/main/mdo/maven.mdo</model>
-          </models>
-          <templates>
-            <template>src/main/mdo/model.vm</template>
-          </templates>
-          <params>
-            <param>packageModelV4=org.apache.maven.api.model</param>
-          </params>
-        </configuration>
+        <groupId>org.codehaus.modello</groupId>
+        <artifactId>modello-maven-plugin</artifactId>
         <executions>
           <execution>
-            <id>modello</id>
+            <id>velocity</id>
             <goals>
               <goal>velocity</goal>
             </goals>
+            <configuration>
+              <version>4.2.0</version>
+              <models>
+                <model>src/main/mdo/maven.mdo</model>
+              </models>
+              <templates>
+                <template>src/main/mdo/model.vm</template>
+              </templates>

Review Comment:
   What do you mean exactly ? I don't understand.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] hboutemy commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
hboutemy commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060691858


##########
api/maven-api-model/pom.xml:
##########
@@ -63,26 +63,26 @@ under the License.
         </executions>
       </plugin>
       <plugin>
-        <groupId>org.apache.maven</groupId>
-        <artifactId>modello-plugin-velocity</artifactId>
-        <configuration>
-          <version>4.2.0</version>
-          <models>
-            <model>src/main/mdo/maven.mdo</model>
-          </models>
-          <templates>
-            <template>src/main/mdo/model.vm</template>
-          </templates>
-          <params>
-            <param>packageModelV4=org.apache.maven.api.model</param>
-          </params>
-        </configuration>
+        <groupId>org.codehaus.modello</groupId>
+        <artifactId>modello-maven-plugin</artifactId>
         <executions>
           <execution>
-            <id>modello</id>
+            <id>velocity</id>
             <goals>
               <goal>velocity</goal>
             </goals>
+            <configuration>
+              <version>4.2.0</version>
+              <models>
+                <model>src/main/mdo/maven.mdo</model>
+              </models>
+              <templates>
+                <template>src/main/mdo/model.vm</template>
+              </templates>

Review Comment:
   1. it has been our convention for ever https://github.com/apache/maven/tree/maven-3.9.x/maven-model/src/main/mdo
   2. it's really main code that it generated, then storing in `src/main` makes sense



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] michael-o commented on a diff in pull request #944: [MNG-7652] swtich to Modello Velocity

Posted by GitBox <gi...@apache.org>.
michael-o commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1059784940


##########
api/maven-api-model/pom.xml:
##########
@@ -63,26 +63,26 @@ under the License.
         </executions>
       </plugin>
       <plugin>
-        <groupId>org.apache.maven</groupId>
-        <artifactId>modello-plugin-velocity</artifactId>
-        <configuration>
-          <version>4.2.0</version>
-          <models>
-            <model>src/main/mdo/maven.mdo</model>
-          </models>
-          <templates>
-            <template>src/main/mdo/model.vm</template>
-          </templates>
-          <params>
-            <param>packageModelV4=org.apache.maven.api.model</param>
-          </params>
-        </configuration>
+        <groupId>org.codehaus.modello</groupId>
+        <artifactId>modello-maven-plugin</artifactId>
         <executions>
           <execution>
-            <id>modello</id>
+            <id>velocity</id>
             <goals>
               <goal>velocity</goal>
             </goals>
+            <configuration>
+              <version>4.2.0</version>
+              <models>
+                <model>src/main/mdo/maven.mdo</model>
+              </models>
+              <templates>
+                <template>src/main/mdo/model.vm</template>
+              </templates>

Review Comment:
   Stupid question, do we need this separation between main and test for models at all?



##########
api/pom.xml:
##########
@@ -45,6 +44,27 @@
     <project.directory>api</project.directory>
   </properties>
 
+  <build>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <groupId>org.codehaus.modello</groupId>
+          <artifactId>modello-maven-plugin</artifactId>
+          <executions>
+            <execution>
+              <id>modello-site-docs</id>
+              <goals>
+                <goal>xdoc</goal>
+                <goal>xsd</goal>
+              </goals>
+              <phase>none</phase>

Review Comment:
   This works?



##########
api/maven-api-model/src/main/mdo/model.vm:
##########
@@ -85,7 +85,7 @@
       #end
     #end
 // =================== DO NOT EDIT THIS FILE ====================
-//   Generated by Maven, any modifications will be overwritten.
+//   ${generatedBy}

Review Comment:
   This I would like to know as well



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] hboutemy merged pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
hboutemy merged PR #944:
URL: https://github.com/apache/maven/pull/944


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] michael-o commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
michael-o commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060715950


##########
api/maven-api-model/pom.xml:
##########
@@ -63,26 +63,26 @@ under the License.
         </executions>
       </plugin>
       <plugin>
-        <groupId>org.apache.maven</groupId>
-        <artifactId>modello-plugin-velocity</artifactId>
-        <configuration>
-          <version>4.2.0</version>
-          <models>
-            <model>src/main/mdo/maven.mdo</model>
-          </models>
-          <templates>
-            <template>src/main/mdo/model.vm</template>
-          </templates>
-          <params>
-            <param>packageModelV4=org.apache.maven.api.model</param>
-          </params>
-        </configuration>
+        <groupId>org.codehaus.modello</groupId>
+        <artifactId>modello-maven-plugin</artifactId>
         <executions>
           <execution>
-            <id>modello</id>
+            <id>velocity</id>
             <goals>
               <goal>velocity</goal>
             </goals>
+            <configuration>
+              <version>4.2.0</version>
+              <models>
+                <model>src/main/mdo/maven.mdo</model>
+              </models>
+              <templates>
+                <template>src/main/mdo/model.vm</template>
+              </templates>

Review Comment:
   Agreed.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] michael-o commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
michael-o commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060326967


##########
api/maven-api-model/src/main/mdo/model.vm:
##########
@@ -85,7 +85,7 @@
       #end
     #end
 // =================== DO NOT EDIT THIS FILE ====================
-//   Generated by Maven, any modifications will be overwritten.
+//   ${generatedBy}

Review Comment:
   From this documentation point of view this makes sense... otherwise it is confusing because only `templatePath` should be a Velocity property.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] michael-o commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
michael-o commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060327463


##########
api/pom.xml:
##########
@@ -45,6 +44,27 @@
     <project.directory>api</project.directory>
   </properties>
 
+  <build>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <groupId>org.codehaus.modello</groupId>
+          <artifactId>modello-maven-plugin</artifactId>
+          <executions>
+            <execution>
+              <id>modello-site-docs</id>
+              <goals>
+                <goal>xdoc</goal>
+                <goal>xsd</goal>
+              </goals>
+              <phase>none</phase>

Review Comment:
   Nice...



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] gnodet commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
gnodet commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060357689


##########
api/pom.xml:
##########
@@ -45,6 +44,27 @@
     <project.directory>api</project.directory>
   </properties>
 
+  <build>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <groupId>org.codehaus.modello</groupId>
+          <artifactId>modello-maven-plugin</artifactId>
+          <executions>
+            <execution>
+              <id>modello-site-docs</id>
+              <goals>
+                <goal>xdoc</goal>
+                <goal>xsd</goal>
+              </goals>
+              <phase>none</phase>

Review Comment:
   > Nice...
   
   Not really.  It's a workaround for the inability to disable a plugin execution, but it works...



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] gnodet commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
gnodet commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060203571


##########
api/maven-api-model/src/main/mdo/model.vm:
##########
@@ -85,7 +85,7 @@
       #end
     #end
 // =================== DO NOT EDIT THIS FILE ====================
-//   Generated by Maven, any modifications will be overwritten.
+//   ${generatedBy}

Review Comment:
   Here's the answer: https://github.com/codehaus-plexus/modello/blob/master/modello-plugins/modello-plugin-velocity/src/main/java/org/codehaus/modello/plugin/velocity/VelocityGenerator.java#L85



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] gnodet commented on a diff in pull request #944: [MNG-7652] swtich to Modello Velocity

Posted by GitBox <gi...@apache.org>.
gnodet commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1059774288


##########
api/maven-api-model/src/main/mdo/model.vm:
##########
@@ -85,7 +85,7 @@
       #end
     #end
 // =================== DO NOT EDIT THIS FILE ====================
-//   Generated by Maven, any modifications will be overwritten.
+//   ${generatedBy}

Review Comment:
   Is this defined somewhere ? I can't find any definition for this variable.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] hboutemy commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
hboutemy commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060323593


##########
api/maven-api-model/src/main/mdo/model.vm:
##########
@@ -85,7 +85,7 @@
       #end
     #end
 // =================== DO NOT EDIT THIS FILE ====================
-//   Generated by Maven, any modifications will be overwritten.
+//   ${generatedBy}

Review Comment:
   even simpler: the user documentation https://codehaus-plexus.github.io/modello/modello-plugins/modello-plugin-velocity/



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] hboutemy commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
hboutemy commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060691858


##########
api/maven-api-model/pom.xml:
##########
@@ -63,26 +63,26 @@ under the License.
         </executions>
       </plugin>
       <plugin>
-        <groupId>org.apache.maven</groupId>
-        <artifactId>modello-plugin-velocity</artifactId>
-        <configuration>
-          <version>4.2.0</version>
-          <models>
-            <model>src/main/mdo/maven.mdo</model>
-          </models>
-          <templates>
-            <template>src/main/mdo/model.vm</template>
-          </templates>
-          <params>
-            <param>packageModelV4=org.apache.maven.api.model</param>
-          </params>
-        </configuration>
+        <groupId>org.codehaus.modello</groupId>
+        <artifactId>modello-maven-plugin</artifactId>
         <executions>
           <execution>
-            <id>modello</id>
+            <id>velocity</id>
             <goals>
               <goal>velocity</goal>
             </goals>
+            <configuration>
+              <version>4.2.0</version>
+              <models>
+                <model>src/main/mdo/maven.mdo</model>
+              </models>
+              <templates>
+                <template>src/main/mdo/model.vm</template>
+              </templates>

Review Comment:
   1. it has been our convention for ever https://github.com/apache/maven/tree/maven-3.9.x/maven-model/src/main/mdo
   2. it's really main code that it generated, then storing in `src/main` makes sense
   3. IIRC, in some cases, we generated test code from models, storing model in `src/test/mdo`: unusual, but real



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] hboutemy commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
hboutemy commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060323593


##########
api/maven-api-model/src/main/mdo/model.vm:
##########
@@ -85,7 +85,7 @@
       #end
     #end
 // =================== DO NOT EDIT THIS FILE ====================
-//   Generated by Maven, any modifications will be overwritten.
+//   ${generatedBy}

Review Comment:
   even better: the user documenattion https://codehaus-plexus.github.io/modello/modello-plugins/modello-plugin-velocity/



##########
api/maven-api-model/src/main/mdo/model.vm:
##########
@@ -85,7 +85,7 @@
       #end
     #end
 // =================== DO NOT EDIT THIS FILE ====================
-//   Generated by Maven, any modifications will be overwritten.
+//   ${generatedBy}

Review Comment:
   even better: the user documentation https://codehaus-plexus.github.io/modello/modello-plugins/modello-plugin-velocity/



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] gnodet commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
gnodet commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060357689


##########
api/pom.xml:
##########
@@ -45,6 +44,27 @@
     <project.directory>api</project.directory>
   </properties>
 
+  <build>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <groupId>org.codehaus.modello</groupId>
+          <artifactId>modello-maven-plugin</artifactId>
+          <executions>
+            <execution>
+              <id>modello-site-docs</id>
+              <goals>
+                <goal>xdoc</goal>
+                <goal>xsd</goal>
+              </goals>
+              <phase>none</phase>

Review Comment:
   > Nice...
   
   Not really.  It's a workaround for the inability to disable a plugin execution imho.  But it works...



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [maven] michael-o commented on a diff in pull request #944: [MNG-7652] switch to Modello Velocity

Posted by GitBox <gi...@apache.org>.
michael-o commented on code in PR #944:
URL: https://github.com/apache/maven/pull/944#discussion_r1060327152


##########
api/maven-api-model/pom.xml:
##########
@@ -63,26 +63,26 @@ under the License.
         </executions>
       </plugin>
       <plugin>
-        <groupId>org.apache.maven</groupId>
-        <artifactId>modello-plugin-velocity</artifactId>
-        <configuration>
-          <version>4.2.0</version>
-          <models>
-            <model>src/main/mdo/maven.mdo</model>
-          </models>
-          <templates>
-            <template>src/main/mdo/model.vm</template>
-          </templates>
-          <params>
-            <param>packageModelV4=org.apache.maven.api.model</param>
-          </params>
-        </configuration>
+        <groupId>org.codehaus.modello</groupId>
+        <artifactId>modello-maven-plugin</artifactId>
         <executions>
           <execution>
-            <id>modello</id>
+            <id>velocity</id>
             <goals>
               <goal>velocity</goal>
             </goals>
+            <configuration>
+              <version>4.2.0</version>
+              <models>
+                <model>src/main/mdo/maven.mdo</model>
+              </models>
+              <templates>
+                <template>src/main/mdo/model.vm</template>
+              </templates>

Review Comment:
   What is the purpose of having those models in `main` if we will never distinct between `main` and `test`?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org