ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hi...@apache.org
Subject svn commit: r988463 - in /ant/ivy/ivyde/trunk: ./ org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/ org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/workspaceresolver/ test/workspaceresolver-self-dep/ test/workspaceresol...
Date Tue, 24 Aug 2010 10:14:56 GMT
Author: hibou
Date: Tue Aug 24 10:14:55 2010
New Revision: 988463

URL: http://svn.apache.org/viewvc?rev=988463&view=rev
Log:
IVYDE-240: WorkspaceResolver: deal with self-dependencies

Added:
    ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/   (with props)
    ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.classpath
    ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.project
    ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy.xml   (with props)
    ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy2.xml   (with props)
    ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivysettings.xml   (with props)
    ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/src/
Modified:
    ant/ivy/ivyde/trunk/CHANGES.txt
    ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyClasspathContainerMapper.java
    ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/workspaceresolver/WorkspaceResolver.java

Modified: ant/ivy/ivyde/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/CHANGES.txt?rev=988463&r1=988462&r2=988463&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/CHANGES.txt (original)
+++ ant/ivy/ivyde/trunk/CHANGES.txt Tue Aug 24 10:14:55 2010
@@ -11,6 +11,7 @@
 - IMPROVE: let IvyDE refresh workspace after a resolve (IVYDE-27) (thanks to Clint Burghduff)
 - IMPROVE: IvyDE now resolve by batch, then preventing too many workspace build (IVYDE-177)
 - IMPROVE: Shared Javadoc/Source attachments (IVYDE-230) (thanks to Gregory Fernandez)
+- IMPROVE: WorkspaceResolver: deal with self-dependencies (IVYDE-240)
 
 - FIX: Variable based path for ivysettings doesn't work it there are some spaces in the path
(IVYDE-253)
 - FIX: Triggers are not called (IVYDE-244)

Modified: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyClasspathContainerMapper.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyClasspathContainerMapper.java?rev=988463&r1=988462&r2=988463&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyClasspathContainerMapper.java
(original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyClasspathContainerMapper.java
Tue Aug 24 10:14:55 2010
@@ -83,7 +83,10 @@ public class IvyClasspathContainerMapper
 
             if (artifact.getType().equals(WorkspaceResolver.ECLIPSE_PROJECT_TYPE)) {
                 // This is a java project in the workspace, add project path
-                paths.add(JavaCore.newProjectEntry(new Path(artifact.getName()), true));
+                // but only add it if it is not a self dependency
+                if (!artifact.getName().equals(conf.getJavaProject().getPath().toString()))
{
+                    paths.add(JavaCore.newProjectEntry(new Path(artifact.getName()), true));
+                }
             } else if (artifact.getLocalFile() != null && accept(artifact.getArtifact()))
{
                 Path classpathArtifact = getArtifactPath(artifact);
                 Path sourcesArtifact = getArtifactPath(artifact, sourceArtifactMatcher,

Modified: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/workspaceresolver/WorkspaceResolver.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/workspaceresolver/WorkspaceResolver.java?rev=988463&r1=988462&r2=988463&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/workspaceresolver/WorkspaceResolver.java
(original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/workspaceresolver/WorkspaceResolver.java
Tue Aug 24 10:14:55 2010
@@ -157,10 +157,6 @@ public class WorkspaceResolver extends A
         // container for this dependency
         for (int i = 0; i < projects.length; i++) {
             IJavaProject javaProject = projects[i];
-            if (resolvingJavaProject.equals(javaProject)) {
-                // we don't want to introduce self dependency
-                continue;
-            }
             if (!javaProject.exists()) {
                 continue;
             }

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Tue Aug 24 10:14:55 2010
@@ -0,0 +1 @@
+bin

Added: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.classpath
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.classpath?rev=988463&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.classpath (added)
+++ ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.classpath Tue Aug 24 10:14:55 2010
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="con" path="org.apache.ivyde.eclipse.cpcontainer.IVYDE_CONTAINER/?ivyXmlPath=ivy.xml&amp;confs=*&amp;ivySettingsPath=%24%7Bworkspace_loc%3Aivydetest-workspaceresolver-common%2Fivysettings.xml%7D&amp;loadSettingsOnDemand=false&amp;propertyFiles=&amp;acceptedTypes=jar&amp;sourceTypes=source&amp;javadocTypes=javadoc&amp;sourceSuffixes=-source%2C-sources%2C-src&amp;javadocSuffixes=-javadoc%2C-javadocs%2C-doc%2C-docs&amp;alphaOrder=false&amp;resolveInWorkspace=true&amp;resolveBeforeLaunch=false&amp;retrievedClasspath=false&amp;mapIfOnlyOneSource=false&amp;mapIfOnlyOneJavadoc=false"/>
+	<classpathentry kind="con" path="org.apache.ivyde.eclipse.cpcontainer.IVYDE_CONTAINER/?ivyXmlPath=ivy2.xml&amp;confs=*&amp;acceptedTypes=jar%2Cbundle%2Cejb%2Cmaven-plugin&amp;sourceTypes=source&amp;javadocTypes=javadoc&amp;sourceSuffixes=-source%2C-sources%2C-src&amp;javadocSuffixes=-javadoc%2C-javadocs%2C-doc%2C-docs&amp;alphaOrder=false&amp;resolveInWorkspace=true&amp;resolveBeforeLaunch=false&amp;retrievedClasspath=false&amp;mapIfOnlyOneSource=false&amp;mapIfOnlyOneJavadoc=false"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>

Added: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.project
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.project?rev=988463&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.project (added)
+++ ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/.project Tue Aug 24 10:14:55 2010
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>ivydetest-workspaceresolver-self-dep</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+		<nature>org.apache.ivyde.eclipse.ivyNature</nature>
+	</natures>
+</projectDescription>

Added: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy.xml
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy.xml?rev=988463&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy.xml (added)
+++ ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy.xml Tue Aug 24 10:14:55 2010
@@ -0,0 +1,30 @@
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one
+   or more contributor license agreements.  See the NOTICE file
+   distributed with this work for additional information
+   regarding copyright ownership.  The ASF licenses this file
+   to you under the Apache License, Version 2.0 (the
+   "License"); you may not use this file except in compliance
+   with the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing,
+   software distributed under the License is distributed on an
+   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   KIND, either express or implied.  See the License for the
+   specific language governing permissions and limitations
+   under the License.    
+-->
+<ivy-module version="1.0">
+    <info organisation="org.apache.ivyde" module="ivydetest-workspaceresolver-self-dep"
revision="1.1">
+        <description>
+            Project using the resolve in workspace feature while having a dependency on itself
+        </description>
+    </info>
+    <configurations>
+        <conf name="default" />
+    </configurations>
+    <dependencies>
+    </dependencies>
+</ivy-module>

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision Author HeadURL Id

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy2.xml
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy2.xml?rev=988463&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy2.xml (added)
+++ ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy2.xml Tue Aug 24 10:14:55 2010
@@ -0,0 +1,31 @@
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one
+   or more contributor license agreements.  See the NOTICE file
+   distributed with this work for additional information
+   regarding copyright ownership.  The ASF licenses this file
+   to you under the Apache License, Version 2.0 (the
+   "License"); you may not use this file except in compliance
+   with the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing,
+   software distributed under the License is distributed on an
+   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   KIND, either express or implied.  See the License for the
+   specific language governing permissions and limitations
+   under the License.    
+-->
+<ivy-module version="1.0">
+    <info organisation="org.apache.ivyde" module="ivydetest-workspaceresolver-self-dep2"
revision="1.1">
+        <description>
+            Project using the resolve in workspace feature while having a dependency on itself
+        </description>
+    </info>
+    <configurations>
+        <conf name="default" />
+    </configurations>
+    <dependencies>
+        <dependency org="org.apache.ivyde" name="ivydetest-workspaceresolver-self-dep"
rev="[1.1,1.2)" conf="default" />
+    </dependencies>
+</ivy-module>

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy2.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy2.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision Author HeadURL Id

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivy2.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivysettings.xml
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivysettings.xml?rev=988463&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivysettings.xml (added)
+++ ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivysettings.xml Tue Aug 24 10:14:55
2010
@@ -0,0 +1,33 @@
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one
+   or more contributor license agreements.  See the NOTICE file
+   distributed with this work for additional information
+   regarding copyright ownership.  The ASF licenses this file
+   to you under the Apache License, Version 2.0 (the
+   "License"); you may not use this file except in compliance
+   with the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing,
+   software distributed under the License is distributed on an
+   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   KIND, either express or implied.  See the License for the
+   specific language governing permissions and limitations
+   under the License.    
+-->
+<ivysettings>
+    <caches defaultCacheDir="${ivy.settings.dir}/../cache-fakerepo" useOrigin="false"
checkUpToDate="true" />
+    <settings defaultResolver="chain" />
+    <resolvers>
+        <filesystem name="fakerepo" checkmodified="true">
+            <ivy pattern="${ivy.settings.dir}/../fakerepo/[organisation]/[module]/ivy-[revision].xml"/>
+            <artifact pattern="${ivy.settings.dir}/../fakerepo/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
+        </filesystem>
+        <ibiblio name="ibiblio" m2compatible="true" />
+        <chain name="chain">
+        	<resolver ref="fakerepo" />
+        	<resolver ref="ibiblio" />
+        </chain>
+    </resolvers>
+</ivysettings>

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivysettings.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivysettings.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision Author HeadURL Id

Propchange: ant/ivy/ivyde/trunk/test/workspaceresolver-self-dep/ivysettings.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml



Mime
View raw message