[GRADLE-436] archive_war task fails if the target build dir is a nested directory Created: 06/Apr/09 Updated: 04/Jan/13 Resolved: 18/Apr/09 |
|
Status: | Resolved |
Project: | Gradle |
Affects Version/s: | 0.5.2 |
Fix Version/s: | 0.6 |
Type: | Bug | ||
Reporter: | Colin Yates | Assignee: | Hans Dockter |
Resolution: | Not A Bug | Votes: | 0 |
Attachments: | nested-web.zip |
Description |
(this looks like a duplicate of http://jira.codehaus.org/browse/GRADLE-131) Hi, I have the following structure:
root/settings.gradle includes jonah/nah If I build webapps/webapp1 then it fails with the following error message: — start Build failed with an exception. Build file '/Users/colinyates/Projects/orca/jonah/trunk/jonah/nah/build.gradle' Execution failed for task :jonah/nah:archive_war. BUILD FAILED — end jonah/nah/build.gradle: — start usePlugin('war') dependencies { compile project(':test-utils') compile project(':orca-core') compile project(':orca-support') // REVIEW - move these to a common parent build.settings providedCompile('javax.servlet:servlet-api:2.5') providedCompile('javax.servlet:jsp-api:2.0') compile('javax.servlet:jstl:1.2') }// REVIEW - urgh! The jars on the dependant projects aren't being copied additionalLibs(dir: '../../orca-support/build/') { include('*.jar') } } // create the exploded war — end |
Comments |
Comment by Hans Dockter [ 15/Apr/09 ] |
From your snipped I can't see where you set the non standard build dir. I have played around with what I think are similar scenarios but could not reproduce the bug. A test project that reproduces this bug would help a lot. |
Comment by Colin Yates [ 17/Apr/09 ] |
Attached is a skeleton project. Running gradle dists in the root results in the following: colin-yatess-macbook-pro:nested-web colinyates$ gradle dists Build failed with an exception. Build file '/Users/colinyates/Projects/gradle-test/nested-web/wars/a-webapp/build.gradle' Execution failed for task :wars/a-webapp:archive_war. BUILD FAILED Total time: 4.689 secs |
Comment by Hans Dockter [ 17/Apr/09 ] |
Thanks for the test case. I have the problem that when I unpack nested-web.tgz, the nested-web/build.gradle is an empty document and I can't reproduce the above output. |
Comment by Colin Yates [ 17/Apr/09 ] |
uploaded a new zip file. Apologies for that |
Comment by Hans Dockter [ 18/Apr/09 ] |
There is a bug in your settings.gradle. Instead of "wars/a-project" the path must be described as "wars:a-project". We use a different path separator, because Gradle has special tasks where the normal path separator can be part of the task name. We are aware that this is not intuitive. For 0.7 we are thinking about ways to use the normal path separator for project paths and still be able to use the path separator in task names. |