continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From eveni...@apache.org
Subject svn commit: r312718 - in /maven/continuum/trunk: continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/ continuum-core/src/main/java/org/apache/maven/continuum/utils/ continuum-model/src/main/mdo/
Date Mon, 10 Oct 2005 19:28:58 GMT
Author: evenisse
Date: Mon Oct 10 12:28:51 2005
New Revision: 312718

URL: http://svn.apache.org/viewcvs?rev=312718&view=rev
Log:
Add parent to project.

Modified:
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java
    maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java?rev=312718&r1=312717&r2=312718&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java
Mon Oct 10 12:28:51 2005
@@ -151,6 +151,25 @@
         }
 
         // ----------------------------------------------------------------------
+        // Parent
+        // ----------------------------------------------------------------------
+
+        if ( mavenProject.getParent() != null )
+        {
+            MavenProject parentProject = mavenProject.getParent();
+
+            ProjectDependency parent = new ProjectDependency();
+
+            parent.setGroupId( parentProject.getGroupId() );
+
+            parent.setArtifactId( parentProject.getArtifactId() );
+
+            parent.setVersion( parentProject.getVersion() );
+
+            continuumProject.setParent( parent );
+        }
+
+        // ----------------------------------------------------------------------
         // Dependencies
         // ----------------------------------------------------------------------
 
@@ -174,7 +193,6 @@
             }
 
             continuumProject.setDependencies( dependencies );
-            
         }
 
         // ----------------------------------------------------------------------

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java?rev=312718&r1=312717&r2=312718&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java
Mon Oct 10 12:28:51 2005
@@ -77,6 +77,20 @@
 
             String id = getProjectId( project );
 
+            // Parent
+            ProjectDependency parent = project.getParent();
+
+            if ( parent != null )
+            {
+                String dependencyId = getDependencyId( parent );
+
+                if ( dag.getVertex( dependencyId ) != null )
+                {
+                    dag.addEdge( id, dependencyId );
+                }
+            }
+
+            // Dependencies
             for ( Iterator j = project.getDependencies().iterator(); j.hasNext(); )
             {
                 ProjectDependency dependency = (ProjectDependency) j.next();

Modified: maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo?rev=312718&r1=312717&r2=312718&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo (original)
+++ maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo Mon Oct 10 12:28:51 2005
@@ -165,6 +165,13 @@
           </association>
         </field>
         <field jpox.fetchGroupNames="project-all-details">
+          <name>parent</name>
+          <version>1.0.0+</version>
+          <association jpox.join="false">
+            <type>ProjectDependency</type>
+          </association>
+        </field>
+        <field jpox.fetchGroupNames="project-all-details">
           <name>dependencies</name>
           <version>1.0.0+</version>
           <association jpox.join="false">



Mime
View raw message