我正在尝试为play framework 2.1.1安装maven模块,我无法弄清楚为什么“install”命令不可用:
来自项目:
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.
答案 0 :(得分:3)
install
命令仅适用于Play 1.x,module directory列出的模块也是如此。有一些modules for 2.1.1。
要在Play 2.x项目中安装模块,您必须在project/Build.scala
中将它们添加为依赖项。该模块的自述文件应告诉您如何使其运行。