Skip to content

Commit 8a4ce4f

Browse files
authored
Fix pom scope for Scala projects (#1531)
Required the `api` dependency method from the `java-library` plugin. Now the scope is `compile` (api) instead of `runtime` (implementation). JAVA-5647
1 parent 877425e commit 8a4ce4f

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

bson-scala/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ description = "A Scala wrapper / extension to the bson library"
1818
archivesBaseName = 'mongo-scala-bson'
1919

2020
dependencies {
21-
implementation project(path: ':bson', configuration: 'default')
21+
api project(path: ':bson', configuration: 'default')
2222
}
2323

2424
sourceSets {

build.gradle

+3-2
Original file line numberDiff line numberDiff line change
@@ -109,15 +109,16 @@ configure(javaProjects) {
109109

110110
configure(scalaProjects) {
111111
apply plugin: 'scala'
112+
apply plugin: 'java-library'
112113
apply plugin: 'idea'
113114
apply plugin: "com.adtran.scala-multiversion-plugin"
114115
apply plugin: "com.diffplug.spotless"
115116

116117
group = 'org.mongodb.scala'
117118

118119
dependencies {
119-
implementation ('org.scala-lang:scala-library:%scala-version%')
120-
implementation ('org.scala-lang:scala-reflect:%scala-version%')
120+
api ('org.scala-lang:scala-library:%scala-version%')
121+
api ('org.scala-lang:scala-reflect:%scala-version%')
121122

122123
testImplementation(platform("org.junit:junit-bom:$junitBomVersion"))
123124
testImplementation("org.junit.vintage:junit-vintage-engine")

driver-scala/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ archivesBaseName = 'mongo-scala-driver'
1919

2020

2121
dependencies {
22-
implementation project(path: ':bson-scala', configuration: 'default')
23-
implementation project(path: ':driver-reactive-streams', configuration: 'default')
22+
api project(path: ':bson-scala', configuration: 'default')
23+
api project(path: ':driver-reactive-streams', configuration: 'default')
2424
compileOnly 'com.google.code.findbugs:jsr305:1.3.9'
2525

2626
testImplementation project(':driver-sync')

0 commit comments

Comments
 (0)