On Wed, Mar 31, 2010 at 4:24 PM, Geronimo M. H. <[email protected]>wrote:
> Hello,
>
> the release-notes talk about the incremental build, which now works for
> every
> task.
>
> Does gradle compare the result (i.e. *.class) with the source (i.e. *.java)
>
Each task can have a set of inputs and outputs which are checked for the
incremental build.
and if so, how do I declare such a dependency for custom tasks?
>
There are two ways to add to the inputs and outputs of a task.
One is via annotating the properties, the other is via the api.
class MyTask extends DefaultTask {
@InputDir
File someDir
Each task has an instance of TaskOutputs and TaskInputs accessible via th
inputs and outputs properties.
You can say stuff like:
inputs.dir 'someDir'
Have a look at the Javadoc for more details. You can even add non file based
input properties (e.g. something like sourcecompatibility).
> If gradle has another way to keep track of changes, how can I ask for a
> treeSet of the changed sources inside a task definition?
>
The API for asking about the results of the incremental build check is not
exposed yet. This is on the list (not for 0.9 though).
- Hans
--
Hans Dockter
Founder, Gradle
http://www.gradle.org, http://twitter.com/gradleorg
CEO, Gradle Inc. - Gradle Training, Support, Consulting
http://www.gradle.biz
>
> kind regards
>
> Geronimo
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
> http://xircles.codehaus.org/manage_email
>
>
>