Hey,
I don't see anything specific in your snippet that alters the
already-resolved configuration and hence leads to the exception. Might be
that some other part of your build is altering the resolved configuration?
I'd suggest to nail it down (for example - does it fail only for 'common'
project if the task is configured in the main build.gradle?)
>is there anything to solve it and remove the duplication?
allprojects {} is a good way to rid this duplication. Other might be "apply
from: 'common.gradle' ".
Cheers!
On Sun, Aug 7, 2011 at 5:08 AM, asafdav2 <[email protected]> wrote:
> hello
> i'm using gradle 0.9.2
> my apiviz task looks like this:
>
> task apiviz (type: Javadoc, dependsOn: build) {
> source sourceSets.main.allJava
> options.classpath sourceSets.main.compileClasspath as List
> options.docklet = "org.jboss.apiviz.APIviz"
> options.docletpath = configurations.apivizConf as List
> }
>
> currently i have to duplicate this task definition in every module of my
> multi-module project. if i try to put it in the base gradle file under
> allProjects {}, i'm getting this error message:
>
> A problem occured evaluating project ':common'.
> Cause: You can't change a configuration which is not in unresolved state!
>
> is there anything to solve it and remove the duplication?
>
> --
> View this message in context:
> http://gradle.1045684.n5.nabble.com/need-help-with-apiviz-task-for-multi-module-project-tp4674148p4674148.html
> Sent from the gradle-user mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
> http://xircles.codehaus.org/manage_email
>
>
>
--
Szczepan Faber
Principal engineer@gradleware
Lead@mockito