Changeset 5334 for branches/release-0.15.x/pustefix-live/src/main/java/org/pustefixframework/live/LiveResolver.java
- Timestamp:
- 09/01/10 16:16:44 (21 months ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
branches/release-0.15.x/pustefix-live/src/main/java/org/pustefixframework/live/LiveResolver.java
r5331 r5334 64 64 throw new IllegalArgumentException(path); 65 65 } 66 66 67 67 if (file.exists()) { 68 68 url = file.toURI().toURL(); … … 93 93 LOG.debug("Resolving live module root from live.xml for " + url + ":" + path); 94 94 } 95 95 96 96 if (path.startsWith("/")) { 97 97 path = path.substring(1); … … 185 185 } 186 186 187 private static File guessFallbackDocroot(String srcMainWebapp) {187 private static File guessFallbackDocroot(String srcMainWebapp) throws Exception { 188 188 File srcMainWebappDir = new File(srcMainWebapp); 189 189 if (srcMainWebappDir.exists() && srcMainWebappDir.isDirectory()) { 190 190 File projectDir = srcMainWebappDir.getParentFile().getParentFile().getParentFile(); 191 File pomFile = LiveUtils.guessPom(srcMainWebapp); 191 192 File target = new File(projectDir, "target"); 192 if (target.exists() && target.isDirectory()) { 193 if (pomFile != null && pomFile.exists() && target.exists() && target.isDirectory()) { 194 String artifactId = LiveUtils.getArtifactFromPom(pomFile); 193 195 for (File file : target.listFiles()) { 194 if (file.isDirectory() ) {196 if (file.isDirectory() && file.getName().startsWith(artifactId)) { 195 197 File webInfDir = new File(file, "WEB-INF"); 196 198 if (webInfDir.exists())
