UniFormal / MMT

The MMT Language and System
https://uniformal.github.io/
Other
68 stars 23 forks source link

Specify deploy/lib/*.jar dependencies in SBT #447

Closed ComFreek closed 5 years ago

ComFreek commented 5 years ago

For almost all jars in deploy/lib (except xz.jar, I guess) there is an official artifact available, e.g. on Maven Central. Drop the jars and specify these dependencies in src/build.sbt.

Reasoning: Usage of MMT via SBT breaks

If one doesn't use the MMT jar, but instead MMT published locally via SBT (see #442 for my setup), then these dependencies are simply not known to SBT. Hence, any usage of them at runtime will lead to errors. E.g. a simple ctrl.handleLine("log+ matcher") caused a NoClassDefFound exception related to scala.util.parsing.Reader. The latter is in the scala-parser-combinators.jar. The fix for my project was to add a (managed!) dependency to it in my build.sbt:

libraryDependencies += "org.scala-lang.modules" %% "scala-parser-combinators" % "1.1.1"

Also I advertized this usage in the "getting started with the MMT API" tutorial, so this also affects end users.

Jazzpirate commented 5 years ago

This has been discussed countless times in our group already. Suffice it to say that all advantages and disadvantages have been brought up and the current way of doing things has been decided to be the most feasible one.

The project setup section in the tutorial will need to be rewritten entirely accordingly. Notably

Open IntelliJ IDEA and create a new "Scala, SBT-based" project

This is already wrong.