Skip to content

Commit 36e5b8f

Browse files
author
Justin Ryan
committed
Adding provided scope
Conflicts: gradle/convention.gradle
1 parent 66ff83f commit 36e5b8f

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

gradle/convention.gradle

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,20 @@ subprojects { project ->
5454
// Ensure output is on a new line
5555
javadoc.doFirst { println "" }
5656

57+
configurations {
58+
provided {
59+
description = 'much like compile, but indicates you expect the JDK or a container to provide it. It is only available on the compilation classpath, and is not transitive.'
60+
transitive = false
61+
visible = false
62+
}
63+
}
64+
65+
project.sourceSets {
66+
main.compileClasspath += project.configurations.provided
67+
main.runtimeClasspath -= project.configurations.provided
68+
test.compileClasspath += project.configurations.provided
69+
test.runtimeClasspath += project.configurations.provided
70+
}
5771
}
5872

5973
task aggregateJavadoc(type: Javadoc) {

0 commit comments

Comments
 (0)