On 13/10/2010, at 4:09 AM, Steve Ebersole wrote:
> I am trying to build a "distribution" of a multi module project. While
> building the release bundles I need to be able to refer to the artifacts
> (jars) built by the modules.
>
> Given a reference to a project, I have tried to use both
> configurations.archives and configurations.default (both of which the user
> guide
> says should contain the project's artifacts). However neither are working as
> expected. This is part of a copySpec:
>
> releaseCopySpec = copySpec {
> ...
> into('lib/required') {
> from parent.project( 'hibernate-core' ).configurations.provided.files {
> dep -> dep.name == 'jta'
> }
> from parent.project( 'hibernate-core' ).configurations.archives
> }
> ...
> }
>
> (I've also tried parent.project( 'hibernate-core' ).configurations.default
> there). But this does not suck the jars produced from the hibernate-core
> project into this copySpec.
>
> Anyone have pointers on what I am doing wrong?
I suspect you're running into http://jira.codehaus.org/browse/GRADLE-732
This issue means that configurations.archives is always empty. A simple
workaround is to use:
from parent.project('hibernate-core').configurations.archives.allArtifactFiles
--
Adam Murdoch
Gradle Developer
http://www.gradle.org
CTO, Gradle Inc. - Gradle Training, Support, Consulting
http://www.gradle.biz