summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xsrc/java/net/sf/antcontrib/net/URLImportTask.java9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/java/net/sf/antcontrib/net/URLImportTask.java b/src/java/net/sf/antcontrib/net/URLImportTask.java
index e513a8a..e95b53d 100755
--- a/src/java/net/sf/antcontrib/net/URLImportTask.java
+++ b/src/java/net/sf/antcontrib/net/URLImportTask.java
@@ -74,6 +74,7 @@ public class URLImportTask
private String repositoryDir;
private URL ivyConfUrl;
private File ivyConfFile;
+ private String resource = "build.xml";
private String artifactPattern = "/[org]/[module]/[ext]s/[module]-[revision].[ext]";
private String ivyPattern = "/[org]/[module]/ivy-[revision].xml";
private boolean verbose = false;
@@ -118,6 +119,10 @@ public class URLImportTask
this.repositoryUrl = repositoryUrl;
}
+ public void setResource(String resource) {
+ this.resource = resource;
+ }
+
public void execute()
throws BuildException {
@@ -244,9 +249,9 @@ public class URLImportTask
expand.setSrc(file);
expand.setDest(dir);
expand.perform();
- importFile = new File(dir, "build.xml");
+ importFile = new File(dir, resource);
if (! importFile.exists()) {
- throw new BuildException("Cannot find a 'build.xml' file in " +
+ throw new BuildException("Cannot find a '" + resource + "' file in " +
file.getName());
}
}