These are chat archives for sbt/sbt

11th
Apr 2015
Michael Loster
@milost
Apr 11 2015 20:17
Hi I'm writing my first sbt autoplugin. Its a plugin that should only work in conjunction with the play framework. I tried to understand the implications of what actually happens when I put addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.3.8") to the project/plugins.sbt file (meta-build) or to the build.sbt file of the proper build. I read the "Organizing the build" section in the documentation but still cannot wrap my head around when the addPlugin statement should go into the "meta-build" and when it should go into the "proper build". Perhaps someone can elaborate a little bit more on that subject. Thx
Dale Wijnand
@dwijnand
Apr 11 2015 20:34
You want to put addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.3.8") in the build.sbt for your plugin, as it's a dependency of your plugin
as opposed to putting it in project/*.sbt because your plugin project isn't also a play project
what also might clarify is the underlining of what addSbtPlugin does: https://github.com/sbt/sbt/blob/0.13.8/main/src/main/scala/sbt/Defaults.scala#L1801-L1820
Jacek Laskowski
@jaceklaskowski
Apr 11 2015 21:49
Where’s sbt-launch in 0.13.9-SNAPSHOT?
Josh Suereth
@jsuereth
Apr 11 2015 21:50
It gets repackaged from github.com/sbt/launcher
Jacek Laskowski
@jaceklaskowski
Apr 11 2015 21:51
oh, @jsuereth is here! So nice
so how to create my own latest sbt?
is this described somewhere?
sbt/sbt + sbt/launcher?
I did sbt publishLocal in sbt/launcher
what’s the next step?
Jacek Laskowski
@jaceklaskowski
Apr 11 2015 21:58
➜  sbt-launcher git:(0.13) ✗ java -jar /Users/jacek/.ivy2/local/org.scala-sbt/launcher/1.0.0-SNAPSHOT/jars/launcher.jar
Error during sbt execution: Could not finder sbt launch configuration.  Searched classpath for:
    /sbt.boot.properties0.13.7
    /sbt/sbt.boot.properties0.13.7
    /sbt.boot.properties0.13
    /sbt/sbt.boot.properties0.13
    /sbt.boot.properties
    /sbt/sbt.boot.properties
Why is the launcher looking for 0.13.7 suffixes not 0.13.8 (the latest version of sbt)?
Josh Suereth
@jsuereth
Apr 11 2015 22:00
Ah, sbt/sbt repackages it....
It comes with no config now
Jacek Laskowski
@jaceklaskowski
Apr 11 2015 22:01
so, what’s the proper command line to execute the latest custom-built sbt?
I publishLocaled sbt/sbt + sbt/launcher
Show sbtLaunchJar should tell you where sbt/sbt repackages it
Jacek Laskowski
@jaceklaskowski
Apr 11 2015 22:07
btw, the autoplugin reminded me about using project/*.scala for it not a separate project that’s linked as a RootProject
doh, how cumbersome I made such a simple task!
Jacek Laskowski
@jaceklaskowski
Apr 11 2015 22:13
bundledLauncherProj/sbtLaunchJar to be precise
Josh Suereth
@jsuereth
Apr 11 2015 22:19
Yeah....
Jacek Laskowski
@jaceklaskowski
Apr 11 2015 22:19
I see in sbt/sbt@9380ca0
and after bundledLauncherProj/sbtLaunchJar that the file ends up in launch/target/sbt-launch.jar
is there a way to publishLocal it or place it under ~/.m2 or ~/.ivy2?
whooohooo!
➜  sbt git:(0.13) ✗ xsbt --launcher-version
JAVA_HOME=/Library/Java/JavaVirtualMachines/java8/Contents/Home
SBT_OPTS= -Xms512M -Xmx1536M -Xss1M -XX:+CMSClassUnloadingEnabled -Dfile.encoding=UTF-8
sbt launcher version 1.0.0-M1