I’ve this task:
task createDemoWar(type: War, dependsOn: classes) {
archiveName "webapi-demo-${versioning.info.display}.war"
destinationDir = file("$buildDir/dist")
copy {
from 'scopes'
include 'configuration.demo.properties'
rename { String fileName ->
fileName.replace('configuration.demo.properties', 'scope.properties')
}
into 'src/main/resources/'
}
}
As you can see I’m trying to copy one single file from scopes folter to /src/main/resources.
In scopes folder there are 4 files. The four files are: configuration.demo.properties
, configuration.dev.properties
, configuration.testing.properties
and configuration.production.properties
.
After having run the task a scope.properties is created however with the content of the fourth file of scopes folder.
Any ideas?