1

我正在尝试为 play framework 2.1.1 安装 maven 模块,但我无法弄清楚为什么“安装”命令不可用:

从一个项目:

play install maven

[info] Loading project definition from C:\someproject
[info] Set current project to SomeProject(in build file:/C:\someproject)
[error] Not a valid command: install (similar: initialize, inspect, shell)
[error] Expected '/'
[error] Expected ':'
[error] Not a valid key: install (similar: initialize, dist, stage)
[error] install
[error]        ^

从任何目录:

play install maven
       _            _
 _ __ | | __ _ _  _| |
| '_ \| |/ _' | || |_|
|  __/|_|\____|\__ (_)
|_|            |__/ 

play! 2.1.1 (using Java 1.7.0_21 and Scala 2.10.0), http://www.playframework.org


This is not a play application!

Use `play new` to create a new Play application in the current directory,
 or go to an existing application and launch the development console using `play`
.

You can also browse the complete documentation at http://www.playframework.org.
4

1 回答 1

3

该命令仅适用于 Play 1.x,模块目录install中列出的模块也是如此。2.1.1有一些模块。

要在 Play 2.x 项目中安装模块,您必须将它们作为依赖项添加到project/Build.scala. 模块的自述文件应该告诉你如何让它运行。

于 2013-08-16T04:27:02.140 回答