Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SBT: how to prevent scala-library from being added to pom automatically?

In a project that consists of Java-only sources with Scala tests and which is built with SBT 0.11.2, I have followed the instructions to have the artifacts uploaded to Maven Central. This worked fine, except for the fact that scala-library is listed as a compile-time dependency in the pom, which I don't want, because it would cause the users of my library to pull scala as a transitive dependency. Is there a way to prevent this dependency from being added?

The exact build.sbt I use can be seen on github.

like image 939
narthi Avatar asked Mar 13 '12 07:03

narthi


1 Answers

In your build.sbt set autoScalaLibrary := false this removes the dependency to the scala-library.

like image 109
drexin Avatar answered Nov 16 '22 02:11

drexin