Index: src/java/fr/jayasoft/ivy/ant/IvyBuildList.java =================================================================== --- src/java/fr/jayasoft/ivy/ant/IvyBuildList.java (revision 537744) +++ src/java/fr/jayasoft/ivy/ant/IvyBuildList.java (working copy) @@ -47,6 +47,8 @@ private boolean _excludeRoot = false; private String _leaf = "*"; private boolean _excludeLeaf = false; + private boolean _transitive = true; + public void addFileset(FileSet buildFiles) { @@ -93,7 +95,15 @@ _excludeLeaf = excludeLeaf; } - public void execute() throws BuildException { + public boolean isTransitive() { + return _transitive; + } + + public void setTransitive(boolean transitive) { + this._transitive = transitive; + } + + public void execute() throws BuildException { if (_reference == null) { throw new BuildException("reference should be provided in ivy build list"); } @@ -210,14 +220,18 @@ // recursively process the nodes Set toKeep = new HashSet(); - processFilterNodeFromRoot(rootmd, toKeep, moduleIdMap); - // With the excluderoot attribute set to true, take the rootmd out of the toKeep set. + // Only add the rootmd to the toKeep set if the excluderoot attribute set to false if (_excludeRoot) { - Message.verbose("Excluded module " + rootmd.getModuleRevisionId().getModuleId().getName()); - toKeep.remove(rootmd); + //Only for logging purposes + Message.verbose("Excluded module " + rootmd.getModuleRevisionId().getModuleId().getName()); + } else { + toKeep.add(rootmd); } + + processFilterNodeFromRoot(rootmd, toKeep, moduleIdMap); + // just for logging for (Iterator iter = toKeep.iterator(); iter.hasNext();) { ModuleDescriptor md = ((ModuleDescriptor) iter.next()); @@ -236,13 +250,14 @@ * @param moduleIdMap reference mapping of moduleId to ModuleDescriptor that are part of the BuildList */ private void processFilterNodeFromRoot(ModuleDescriptor node, Set toKeep, Map moduleIdMap) { - toKeep.add(node); - DependencyDescriptor[] deps = node.getDependencies(); for (int i=0; i