I am using the ShadowJar Gradle plugin to build a Jar containing all of the source files in the src/main/java
directory and other Jar files in a lib
directory and it is working fine. What I need is another ShadowJar task, a devShadowJar
task, that will instead of pulling in a JSON file in the src/main/resources
folder, it will pull in a JSON file in the src/dev/resources
folder.
I added this to the build.gradle
file to define the dev
source set:
sourceSets {
dev
}
But now I am not sure how to create a devShadowJar
task to use the dev
JSON resource instead of the JSON resource file located in src/main/resources
.