These are chat archives for sbt/sbt

4th
Oct 2016
ykycxzsv
@ykycxzsv
Oct 04 2016 07:25
@dwijnand a custom library. i guess it goes into libraryDependencies in project/project/build.sbt, so project/build.sbt can import it
Dale Wijnand
@dwijnand
Oct 04 2016 07:27
oh I see the problem
you want to replace project/Build.scala with a build.sbt file at the root of your project, not inside the project directory
typically the .sbt file inside project is called plugins.sbt because it typically only has sbt plugins (addSbtPlugin(...))
that way when you say "build.sbt" you mean the root one, and "plugins.sbt" to mean the one in the project directory
ykycxzsv
@ykycxzsv
Oct 04 2016 07:31
@dwijnand not quite :) the project already had /build.sbt, /project/build.sbt, /project/plugins.sbt, and /project/Build.scala. it seems that /project/build.sbt defines dependencies that is used by /project/Build.scala
Dale Wijnand
@dwijnand
Oct 04 2016 07:31
correct
ykycxzsv
@ykycxzsv
Oct 04 2016 07:31
so my idea was to move /project/build.sbt to /project/project/build.sbt, and then move the stuff in /project/Build.scala to /project/build.sbt
not sure if that's the right way to go about things
Dale Wijnand
@dwijnand
Oct 04 2016 07:33
no that's not right, you want to keep /project/build.sbt (maybe consider renaming it to /project/plugins.sbt for clarity and/or convention) and merge the setup in /project/Build.scala into /build.sbt
ykycxzsv
@ykycxzsv
Oct 04 2016 07:36
i can't rename /project/build.sbt to /project/plugins.sbt, because there's already a /project/plugins.sbt. do you mean just move the libraryDependencies ++= ... line to plugins.sbt?
Dale Wijnand
@dwijnand
Oct 04 2016 08:42
Yeah. Having them as separate files might be more confusing (you might not remember/realise there's are two files)
ykycxzsv
@ykycxzsv
Oct 04 2016 11:49
i'm already confused as to their difference :) however, moving the contents of /project/Build.scala into /build.sbt rather than into /project/build.sbt was the trick, and works without other changes. thanks!
Guillaume Martres
@smarter
Oct 04 2016 12:30
I'm using sbt with cancelable in Global := true, when I run my application and then ctrl+c it, the sockets it binds are sometimes not unbound, is there any way that I could catch the ctrl+c from my application so that I can close the socket?
Guillaume Martres
@smarter
Oct 04 2016 12:39
It seems that I can fork in run := true and then use Runtime.getRuntime().addShutdownHook to run my finalizer
Justin Kaeser
@jastice
Oct 04 2016 14:08
any way to i solate the classpath of a plugin? -_-
Perry
@pfn
Oct 04 2016 20:15
@jastice, nope