I have a problem copying files in gradle. Here is a build.gradle :
task mydir() { new File("build/models").mkdir() } task copyTask(dependsOn:mydir, type: Copy){ from 'src/test/groovy/models' into 'build/models' from 'src/test/groovy/test.groovy' into 'build/' }
The problem here is in the first instance, i.e. test.groovy is copied to the assembly. But the first copy, where I copy all the files in the src /../ models to the assembly / models, does not work. It just copies files only to the assembly directory. My assemblies / models remain empty. Can someone please tell me what I am doing wrong? I also have a separate task to create the build / models directory before copyTask is executed.
directory gradle
user3721344
source share