From 1ab4b852f31d3dd13bb8c690c9531d13a5a8701a Mon Sep 17 00:00:00 2001 From: Xavier Hanin Date: Tue, 28 Jun 2005 17:53:45 +0000 Subject: [PATCH] fix IllegalStateException from command line on retrieve git-svn-id: https://svn.apache.org/repos/asf/incubator/ivy/trunk@483996 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/fr/jayasoft/ivy/Main.java | 3 +++ src/java/fr/jayasoft/ivy/xml/XmlReportParser.java | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/java/fr/jayasoft/ivy/Main.java b/src/java/fr/jayasoft/ivy/Main.java index acddc170..2dcfa2b1 100644 --- a/src/java/fr/jayasoft/ivy/Main.java +++ b/src/java/fr/jayasoft/ivy/Main.java @@ -161,6 +161,9 @@ public class Main { date, validate).getModuleDescriptor(); + if (confs.length == 1 && "*".equals(confs[0])) { + confs = md.getConfigurationsNames(); + } if (line.hasOption("retrieve")) { String retrievePattern = ivy.substitute(line.getOptionValue("retrieve")); if (retrievePattern.indexOf("[") == -1) { diff --git a/src/java/fr/jayasoft/ivy/xml/XmlReportParser.java b/src/java/fr/jayasoft/ivy/xml/XmlReportParser.java index c4910e6d..ae06b543 100644 --- a/src/java/fr/jayasoft/ivy/xml/XmlReportParser.java +++ b/src/java/fr/jayasoft/ivy/xml/XmlReportParser.java @@ -30,7 +30,7 @@ public class XmlReportParser { public Artifact[] getArtifacts(ModuleId moduleId, String conf, File cache) throws ParseException, IOException { File report = new File(cache, XmlReportOutputter.getReportFileName(moduleId, conf)); if (!report.exists()) { - throw new IllegalStateException("no report file found for "+moduleId+" "+conf+" in "+cache); + throw new IllegalStateException("no report file found for "+moduleId+" "+conf+" in "+cache+": ivy was looking for "+report); } final List artifacts = new ArrayList(); try {