On 29/03/10 3:37 PM, Geronimo M. H. wrote:
On Monday 29 March 2010 06:09:38, Adam Murdoch wrote:
On 28/03/10 5:50 PM, Geronimo M. H. wrote:
Then I learned, that the configurations is a Set of defined
Configurations like "comile" or "runtime", but I did not know about the
"archives" Configuration.
Set the of configurations varies based on which plugins you use, plus
you can add your own configurations for whatever purpose you need.
The user guide chapter for each plugin describes the configurations it
adds. For example, here are the configurations that the java plugin
adds:
http://gradle.org/0.8/docs/userguide/java_plugin.html#sec:java_plugin_and_d
ependency_management
Oh - yes. Shame on me.
I read that chapter. May be it's because I don't understand "Configuration" at
all.
The gradle usage of that class does not fit with my understanding of the
word - so I have to apologize for that. I'm not a native english ...
It doesn't make any sense from a native speaker's point of view, either.
This is one reason why we want to split configurations into 2 pieces: we
can give meaningful names to each piece. Not sure what those might be
yet ...
When I look at the main build-script of gradle:
There you create a new configuration named "dist", which is then used by a
section called artifacts. I don't understand that at all.
What happens with that configuration and who enters values or asks for values?
The uploadDist task uses the configuration, to upload all the artifacts
added to it. The archives { } section adds the artifacts to the
configuration.
I think the fact that this concept lives in 3 different places in the
build file points to the awkwardness of the current model. Something
we'd try to solve in the reworked DSL is to have a way to express this
concisely in a single place in the build file. For example, we might do
something like:
artifacts {
dists { // define a new artifact publication
contains binZip, allZip, srcZip // add in the archives
publishTo webdavRepository(...) // define where it is published to
}
}
This might automatically add a publishDists task which does the work of
publishing the distributions. Or not. We might make it explicit:
artifacts {
dists {
contains binZip, allZip, srcZip
}
}
task uploadDists(type: Upload) {
from artifacts.dists
to webdavRepository(...)
}
--
Adam Murdoch
Gradle Developer
http://www.gradle.org
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email