On Fri, Feb 18, 2011 at 4:13 PM, simonharrer <[email protected]> wrote:

>
> Hi folks,
>
> I now use gradle for my build and this works really well. However, I ran
> into the following problem:
>
> I want to copy the folder "model/" and same files to the classes directory
> during the execution or after the execution of the processResources task.
>

Not sure if this is the best way, but it's a way that will work i'm sure...

task myCopy(type: Copy) {
    from projectDir
    into sourceSets.main.classesDir
    include '**/model/**/*.test'
    include 'plugin.xml'
    include 'plugin.properties'
}

processResources.dependsOn("myCopy")
// or use compileJava.dependsOn("myCopy")



> The following code does not work:
>
> tasks.processResources.doLast {
>        copy {
>                from relativePath(projectDir)
>                into relativePath(project.sourceSets.main.classesDir)
>                include 'plugin.properties'
>                include 'plugin.xml'
>                include 'model/**/*.ecore'
>        }
> }
>
> How can this be achieved?
> --
> View this message in context:
> http://gradle.1045684.n5.nabble.com/Copying-additional-files-during-processResources-tp3391147p3391147.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
>
>
>


-- 
Brett Cave
Systems Architect
Jemstep, Inc

www.jemstep.com

Reply via email to