You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by hi...@apache.org on 2012/07/16 00:39:48 UTC
svn commit: r1361831 - in /ant/ivy/ivyde/trunk: doc/
org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/
org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/preferences/
test/retrieve-in-workspace/ test/retrieve-in-workspace/...
Author: hibou
Date: Sun Jul 15 22:39:47 2012
New Revision: 1361831
URL: http://svn.apache.org/viewvc?rev=1361831&view=rev
Log:
IVYDE-308: Retrieve list does not resolve workspace projects
Added:
ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ (with props)
ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.classpath (with props)
ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.project (with props)
ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.settings/
ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.settings/org.apache.ivyde.eclipse.prefs
ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivy.xml (with props)
ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivysettings.xml (with props)
ant/ivy/ivyde/trunk/test/retrieve-in-workspace/src/
Modified:
ant/ivy/ivyde/trunk/doc/release-notes.html
ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSerializer.java
ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetup.java
ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetupState.java
ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/preferences/EditStandaloneRetrieveDialog.java
Modified: ant/ivy/ivyde/trunk/doc/release-notes.html
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/doc/release-notes.html?rev=1361831&r1=1361830&r2=1361831&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/doc/release-notes.html (original)
+++ ant/ivy/ivyde/trunk/doc/release-notes.html Sun Jul 15 22:39:47 2012
@@ -111,6 +111,7 @@ long, but Apache IvyDE couldn't be what
<li>Clint Burghduff</li>
<li>Gregory Fernandez</li>
<li>Jeffrey M. Metcalf</li>
+<li>Peter Oxenham</li>
<li>Joe Sortelli</li>
</ul>
@@ -122,6 +123,7 @@ List of changes since <a href="/ivy/ivyd
<li>FIX: Divide by zero during IvyDE resolve (IVYDE-312) (thanks to Joe Sortelli)</li>
<li>NEW: Support Accepted Types: * (IVYDE-306)</li>
<li>NEW: Support Workspace/Filesystem/Variables for "Ivy File" setting (IVYDE-304)</li>
+ <li>NEW: Retrieve list does not resolve workspace projects (IVYDE-308) (thanks to Peter Oxenham)</li>
<!-- samples
<li>NEW: new new new (IVYDE-XXX) (thanks to XXX)</li>
<li>IMPROVE: new new new (IVYDE-XXX) (thanks to XXX)</li>
Modified: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSerializer.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSerializer.java?rev=1361831&r1=1361830&r2=1361831&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSerializer.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSerializer.java Sun Jul 15 22:39:47 2012
@@ -76,6 +76,8 @@ public class StandaloneRetrieveSerialize
private static final String RETRIEVE_PATTERN = "pattern";
+ private static final String RESOLVE_IN_WORKSPACE = "resolveInWorkspace";
+
public void write(OutputStream out, List/* <StandaloneRetrieveSetup> */setuplist)
throws IOException {
try {
@@ -98,6 +100,10 @@ public class StandaloneRetrieveSerialize
attr.setValue(setup.getName());
attributes.setNamedItem(attr);
+ attr = document.createAttribute(RESOLVE_IN_WORKSPACE);
+ attr.setValue(Boolean.toString(setup.isResolveInWorkspace()));
+ attributes.setNamedItem(attr);
+
if (setup.isSettingProjectSpecific()) {
Node settingsNode = document.createElement(IVYSETTINGS);
node.appendChild(settingsNode);
@@ -207,6 +213,11 @@ public class StandaloneRetrieveSerialize
NamedNodeMap attributes = node.getAttributes();
setup.setName(getAttribute(attributes, SETUP_NAME));
+ Node attr = attributes.getNamedItem(RESOLVE_IN_WORKSPACE);
+ if (attr != null) {
+ setup.setResolveInWorkspace(Boolean.valueOf(attr.getNodeValue()).booleanValue());
+ }
+
NodeList children = node.getChildNodes();
for (int j = 0; j < children.getLength(); j++) {
Node item = children.item(j);
Modified: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetup.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetup.java?rev=1361831&r1=1361830&r2=1361831&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetup.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetup.java Sun Jul 15 22:39:47 2012
@@ -23,6 +23,8 @@ import org.eclipse.core.resources.IProje
public class StandaloneRetrieveSetup {
+ private boolean resolveInWorkspace;
+
private String name = "dependencies";
private SettingsSetup settingsSetup = new SettingsSetup();
@@ -41,6 +43,15 @@ public class StandaloneRetrieveSetup {
return state;
}
+ public boolean isResolveInWorkspace() {
+ return resolveInWorkspace;
+ }
+
+ public void setResolveInWorkspace(boolean resolveInWorkspace) {
+ this.resolveInWorkspace = resolveInWorkspace;
+ }
+
+
public String getName() {
return name;
}
Modified: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetupState.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetupState.java?rev=1361831&r1=1361830&r2=1361831&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetupState.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/retrieve/StandaloneRetrieveSetupState.java Sun Jul 15 22:39:47 2012
@@ -53,7 +53,7 @@ public class StandaloneRetrieveSetupStat
}
protected boolean isResolveInWorkspace() {
- return false;
+ return setup.isResolveInWorkspace();
}
}
Modified: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/preferences/EditStandaloneRetrieveDialog.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/preferences/EditStandaloneRetrieveDialog.java?rev=1361831&r1=1361830&r2=1361831&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/preferences/EditStandaloneRetrieveDialog.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/ui/preferences/EditStandaloneRetrieveDialog.java Sun Jul 15 22:39:47 2012
@@ -26,6 +26,7 @@ import org.eclipse.jface.dialogs.Dialog;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Label;
@@ -50,6 +51,8 @@ public class EditStandaloneRetrieveDialo
private StandaloneRetrieveSetup setup;
+ private Button resolveInWorkspaceCheck;
+
protected EditStandaloneRetrieveDialog(Shell parentShell, IProject project,
StandaloneRetrieveSetup retrieveSetup) {
super(parentShell);
@@ -75,7 +78,7 @@ public class EditStandaloneRetrieveDialo
retrieveSetup.getSettingsSetup());
ivyFilePathText.init(retrieveSetup.getIvyXmlPath());
retrieveComposite.init(retrieveSetup.getRetrieveSetup());
-
+ resolveInWorkspaceCheck.setSelection(retrieveSetup.isResolveInWorkspace());
return tabs;
}
@@ -101,6 +104,13 @@ public class EditStandaloneRetrieveDialo
ivyFilePathText = new IvyFilePathText(ivyFileComposite, SWT.NONE, project);
ivyFilePathText.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, false, 2, 1));
+ resolveInWorkspaceCheck = new Button(body, SWT.CHECK);
+ resolveInWorkspaceCheck.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true,
+ false, 2, 1));
+ resolveInWorkspaceCheck.setText("Resolve dependencies in workspace");
+ resolveInWorkspaceCheck
+ .setToolTipText("Will replace jars on the classpath with workspace projects");
+
retrieveComposite = new RetrieveComposite(body, SWT.NONE, true);
retrieveComposite.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, false));
@@ -113,6 +123,7 @@ public class EditStandaloneRetrieveDialo
setup.setSettingsSetup(settingsTab.getSettingsEditor().getIvySettingsSetup());
setup.setIvyXmlPath(ivyFilePathText.getIvyFilePath());
setup.setRetrieveSetup(retrieveComposite.getRetrieveSetup());
+ setup.setResolveInWorkspace(resolveInWorkspaceCheck.getSelection());
super.okPressed();
}
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Sun Jul 15 22:39:47 2012
@@ -0,0 +1,2 @@
+bin
+lib
Added: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.classpath
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.classpath?rev=1361831&view=auto
==============================================================================
Binary file - no diff available.
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.classpath
------------------------------------------------------------------------------
svn:mime-type = application/xml
Added: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.project
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.project?rev=1361831&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.project (added)
+++ ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.project Sun Jul 15 22:39:47 2012
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>ivydetest-retrieve-in-workspace</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>
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.project
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.project
------------------------------------------------------------------------------
svn:keywords = Date Revision Author HeadURL Id
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.project
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.settings/org.apache.ivyde.eclipse.prefs
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.settings/org.apache.ivyde.eclipse.prefs?rev=1361831&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.settings/org.apache.ivyde.eclipse.prefs (added)
+++ ant/ivy/ivyde/trunk/test/retrieve-in-workspace/.settings/org.apache.ivyde.eclipse.prefs Sun Jul 15 22:39:47 2012
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+org.apache.ivyde.eclipse.standaloneretrieve=<?xml version\="1.0" encoding\="UTF-8" standalone\="no"?><setuplist><setup name\="dependencies" resolveInWorkspace\="true"><ivysettings loadondemand\="false" path\="${workspace_loc\:ivydetest-retrieve-in-workspace/ivysettings.xml}"/><ivyxml path\="ivy.xml"/><retrieve confs\="*" pattern\="lib/[artifact]-[type].[ext]" sync\="true" types\="*"/></setup></setuplist>
Added: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivy.xml
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivy.xml?rev=1361831&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivy.xml (added)
+++ ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivy.xml Sun Jul 15 22:39:47 2012
@@ -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="ivytest-retrieve-in-workspace">
+ <description>
+ Project that retrieve with the workspace resolver on
+ </description>
+ </info>
+ <configurations>
+ <conf name="default" />
+ </configurations>
+ <dependencies>
+ <dependency org="org.apache.ivyde" name="ivytest-local-cache" rev="latest.integration" conf="default" />
+ </dependencies>
+</ivy-module>
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivy.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivy.xml
------------------------------------------------------------------------------
svn:keywords = Date Revision Author HeadURL Id
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivy.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivysettings.xml
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivysettings.xml?rev=1361831&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivysettings.xml (added)
+++ ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivysettings.xml Sun Jul 15 22:39:47 2012
@@ -0,0 +1,28 @@
+<!--
+ 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="true" />
+ <settings defaultResolver="fakerepo" checkUpToDate="false" />
+ <resolvers>
+ <filesystem name="fakerepo">
+ <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>
+ </resolvers>
+</ivysettings>
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivysettings.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivysettings.xml
------------------------------------------------------------------------------
svn:keywords = Date Revision Author HeadURL Id
Propchange: ant/ivy/ivyde/trunk/test/retrieve-in-workspace/ivysettings.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml