I failed to find a good documentation about the use and purpose of crosspaths. Can someone point me to the documentation or answer these specific questions.
scala
' and 'scala-2.11
'. Shouldn't there
be just one of these two? What is the meaning of these two folders?scala
' and what goes in 'scala-2.11
'?crossPaths
is set to true to enable/disable Cross-Building (and it's true by default).
As of sbt
0.13.8 you're seeing that by default sbt
handles source directories per Scala version, to remove the repetition of every project doing this themselves.
So if you have multiple Scala versions you're cross building against, out the box you have source directories where you can put that version-specific code.
But I agree that it's confusing: if you don't have multiple crossScalaVersions
there's no need for both a scala
and a scala-2.11
.
The majority of your code should always live in scala
, and if you ever have more than one Scala version you're cross building against and you have version-specific code then use scala-2.11
, scala-2.10
, etc.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With