播放2.4 value confDirectory is not member of object play.PlayImport.PlayKeys

Play 2.4 value confDirectory is not a member of object play.PlayImport.PlayKeys

我正在尝试从 2.3 版升级到 Play Framework 2.4 版,但出现以下错误:

value confDirectory is not a member of object play.PlayImport.PlayKeys

此外,我将此导入添加为 play2.4 迁移指南提及但错误仍然存​​在

import play.sbt.PlayImport._

配置目录的正确导入是什么?

看起来密钥确实已被移除。如果您改用 resourceDirectory 会怎样?

lazy val appServerSettings = Seq( 
  loggerConfig := resourceDirectory.value / "application-logger.xml",
  ...
)

在 Play 2.7 中,此键确实指向 conf 目录。