【发布时间】:2014-07-10 01:19:48
【问题描述】:
build.sbt
val Backend = config("backend")
inConfig(Backend)(Defaults.configSettings)
scalaVersion in Backend := "2.11.2-SNAPSHOT"
sbt 复制:
> show backend:scalaInstance
[info] Scala instance{version label 2.10.4, actual version 2.10.4, library jar: /home/masgui/.sbt/boot/scala-2.10.4/lib/scala-library.jar, compiler jar: /home/masgui/.sbt/boot/scala-2.10.4/lib/scala-compiler.jar}
> backend:scalaVersion
[info] 2.11.2-SNAPSHOT
当前工作:
lazy val v = Project(
id = "a",
base = file("woot"),
settings = Project.defaultSettings ++ Seq(
offline := true,
scalaVersion := "2.11.2-SNAPSHOT"
)
)
// ...
scalaInstance in (Backend, Revolver.reStart) := (scalaInstance in v).value
编辑
当我将Classpaths.ivyBaseSettings 添加到后端时,它会忽略ivyConfigurations += Backend
> show ivyConfigurations
[info] List(..., backend)
但是
> backend:update
Cannot add dependency 'com.scalakata#backend_2.11;0.1-20140706T182100' to configuration 'backend' of module com.scalakata#plugin;0.1-20140709T150113 because this configuration doesn't exist!
编辑 我用你以前的一个遮阳篷解决了这个问题:Copy a single dependency jar into a folder via build.sbt
【问题讨论】:
标签: sbt