如何在Play框架2.1中安装插件

时间:2013-09-05 13:47:42

标签: playframework-2.1

我是Play框架的新手,并且正在寻找在我的应用程序中安装play2-morphia-plugin的步骤。请帮我。

1 个答案:

答案 0 :(得分:2)

通常,插件的自述文件文件包含安装指南。

对于您提到的插件,一个简单的搜索会导致github issue about installing the plugin

  

要安装此插件,您必须在项目/ Build.scala中添加它   像这样

val appDependencies = Seq(
  // Add your project dependencies here,
  "leodagdag" % "play2-morphia-plugin_2.9.1" % "0.0.5"
)

val main = PlayProject(appName, appVersion, appDependencies, mainLang = JAVA)
.settings(
  resolvers ++= Seq(DefaultMavenRepository, Resolvers.githubRepository, Resolvers.morphiaRepository)
)

object Resolvers {
  val githubRepository = "LeoDagDag repository" at "http://leodagdag.github.com/repository/"
  val morphiaRepository = "Morphia repository" at "http://morphia.googlecode.com/svn/mavenrepo/"
}