1

我想用我用 Scala 编写的代码和 sbt 和 sbt-native-package 创建一个 Debian 包。

但是当我尝试debian:package-bin在 sbt 控制台中执行时,我收到了这个错误:

[trace] Stack trace suppressed: run last debian:debianControlFile for the full output.
[error] (debian:debianControlFile) packageDescription in Debian cannot be empty. Use
[error]                  packageDescription in Debian := "My package Description"

这很奇怪,因为我build.sbtpackageDescription设置如下:

import com.typesafe.sbt.SbtNativePackager._
import com.typesafe.sbt.packager.Keys._
import NativePackagerKeys._
import com.typesafe.sbt.packager.archetypes.ServerLoader.{SystemV, Upstart}

serverLoading in Debian := SystemV

name := "testApp"

version := "1.0"

organization := "com.testApp"

scalaVersion := "2.10.3"

maintainer in Debian := "gdc <aaa@aaa.com>"

packageSummary in Debian := "testApp"

packageDescription in Debian := "testApp"

packageArchetype.java_server

exportJars := true

我使用packageDescription := "testApp"packageDescription in Linux := "testApp"都没有进行测试。

4

1 回答 1

3

移动线

packageArchetype.java_server

在导入之后,所以它不会覆盖设置。

构建.sbt

import com.typesafe.sbt.SbtNativePackager._
import com.typesafe.sbt.packager.Keys._
import NativePackagerKeys._
import com.typesafe.sbt.packager.archetypes.ServerLoader.{SystemV, Upstart}

packageArchetype.java_server

serverLoading in Debian := SystemV

name := "testApp"

version := "1.0"

organization := "com.testApp"

scalaVersion := "2.10.3"

maintainer in Debian := "gdc <aaa@aaa.com>"

packageSummary in Debian := "testApp"

packageDescription in Debian := "testApp"

exportJars := true
于 2014-06-27T06:28:26.167 回答