SBT打包机大战

时间:2018-12-15 14:54:48

标签: sbt war

根据SBT文档(1.2.x版) -> https://www.scala-sbt.org/1.x/docs/Artifacts.html 有一个packagerWar任务。

// disable .jar publishing 
publishArtifact in (Compile, packageBin) := false 

// create an Artifact for publishing the .war file 
artifact in (Compile, packageWar) := {
  val previous: Artifact = (artifact in (Compile, packageWar)).value
  previous.withType("war").withExtension("war")
} 

// add the .war file to what gets published 
addArtifact(artifact in (Compile, packageWar), packageWar)

packageWar密钥在SBT中不存在。是SBT文档中的错误,还是我对应使用的方式的理解不正确?

0 个答案:

没有答案